🇰🇷 한글 설명
OpenReception 예약 소프트웨어 1.0.2 이전 버전에서는 /logout 페이지의 서버측 로드 핸들러가 내부 로그아웃 API 호출 전에 access_token 쿠키를 먼저 삭제하여, 인증 없이 실행된 로그아웃 요청이 거부되고 DB 세션이 폐기되지 않습니다. 이로 인해 사용자가 로그아웃해도 기존 토큰은 기본 1주일 동안 유효하게 남습니다.
💡 쉬운 설명
사용자가 로그아웃한 것처럼 보여도 서버에서는 실제 로그인 세션이 살아 있습니다. 예전 인증 토큰을 가진 사람은 세션이 자연 만료될 때까지 계속 접근할 수 있습니다.
🇺🇸 원문 (English)
OpenReception's appointment booking software provides an end-to-end encrypted appointment booking platform. Prior to version 1.0.2, when a user navigates to the `/logout` page, the page's server-side load handler deletes the `access_token` cookie before calling `/api/auth/logout` via an internal `event.fetch()`. The internal fetch consequently runs without the auth cookie, so `apiAuthHandle` rejects it, the logout handler never executes, and `SessionService.revokeSession()` is never called for the current session. The DB session row remains valid until its natural expiry (one week by default). The user sees a successful logout (cookie gone, UI returns to login), but any party still holding a copy of the now-deleted access token can continue making authenticated API calls until the session naturally expires. The root cause is a simple ordering mistake. The same auth subsystem implements the correct order in `/api/auth/logout`: revoke the current DB session first, then delete the cookie. The page-level wrapper does the opposite. Version 1.0.2 initiates server-side logout before removing authentication cookies and first appears in version 1.0.2. Version 2.0.0 later replaces this with a race-free client-side logout flow.
📍 영향받는 시스템
OpenReception 1.0.2 이전 버전 (1.0.2에서 처음 도입된 로그아웃 순서 오류, 2.0.0에서 수정)
⚔️ 공격 벡터
탈취되었거나 복사된 access_token 쿠키를 가진 공격자가 로그아웃 이후에도 세션 만료 전까지 인증된 API 호출을 수행
🛡️ 대응 방법
OpenReception을 2.0.0 이상으로 업그레이드하거나 최소 1.0.2 이상으로 업데이트하고, 로그아웃 시 DB 세션을 먼저 폐기한 뒤 쿠키를 삭제하도록 수정
🔧 검증 코드
출력된 버전이 1.0.2 미만이면 취약하므로 업그레이드가 필요하며, 1.0.2 이상이라도 2.0.0 이상인지 확인하는 것이 권장됩니다.
cat package.json 2>/dev/null | grep -E '"version"' || docker inspect --format '{{index .Config.Labels "org.opencontainers.image.version"}}' openreception 2>/dev/null