🇰🇷 한글 설명
Node.js의 HMAC 검증이 상수 시간 비교를 사용하지 않아 응답 시간에 따라 타이밍 정보가 유출됩니다. 고해상도 타이밍 측정이 가능한 환경에서 공격자는 일치하는 바이트 수에 비례한 시간 차이를 측정하여 HMAC 값을 추론할 수 있으며, Node.js가 이미 제공하는 안전한 비교 함수를 사용하지 않은 설계 결함입니다.
💡 쉬운 설명
서명 검증 속도가 올바른 서명과 틀린 서명에 따라 다르게 응답해 공격자가 타이밍으로 정보를 캐낼 수 있습니다. 응답 시간을 측정하면 올바른 서명을 추측할 수 있습니다.
🇺🇸 원문 (English)
A flaw in Node.js HMAC verification uses a non-constant-time comparison when validating user-provided signatures, potentially leaking timing information proportional to the number of matching bytes. Under certain threat models where high-resolution timing measurements are possible, this behavior could be exploited as a timing oracle to infer HMAC values.
Node.js already provides timing-safe comparison primitives used elsewhere in the codebase, indicating this is an oversight rather than an intentional design decision.
This vulnerability affects **20.x, 22.x, 24.x, and 25.x**.
📍 영향받는 시스템
Node.js 20.x, 22.x, 24.x, 25.x
⚔️ 공격 벡터
고해상도 타이밍 오라클 공격으로 응답 시간 측정을 통한 HMAC 값 유추
🛡️ 대응 방법
Node.js를 최신 보안 패치 버전으로 업그레이드하고 crypto.timingSafeEqual() 사용 확인
🔧 검증 코드
v20, v22, v24, v25로 시작하는 버전이 출력되면 영향받는 버전입니다. 패치된 마이너 버전은 보안 권고를 참고하여 확인하세요.
node --version 2>/dev/null | grep -oE 'v(20|22|24|25)\.'