🇰🇷 한글 설명
Node.js의 특정 버전에서 'localhost6'이 화이트리스트에 포함되어 있어 발생하는 DNS 리바인딩 취약점입니다. /etc/hosts 파일에 'localhost6'이 정의되어 있지 않으면 일반 도메인처럼 DNS를 통해 해석되므로, 공격자가 DNS 응답을 조작하여 보안 보호 기능을 우회할 수 있습니다.
💡 쉬운 설명
공격자가 가짜 주소를 이용해 사용자의 컴퓨터 내부 네트워크에 몰래 접근할 수 있는 보안 구멍입니다. 'localhost6'이라는 이름이 실제 내부 주소가 아닌 외부 주소로 속여서 사용될 수 있기 때문에 발생합니다.
🇺🇸 원문 (English)
Node.js before 10.24.0, 12.21.0, 14.16.0, and 15.10.0 is vulnerable to DNS rebinding attacks as the whitelist includes “localhost6”. When “localhost6” is not present in /etc/hosts, it is just an ordinary domain that is resolved via DNS, i.e., over network. If the attacker controls the victim's DNS server or can spoof its responses, the DNS rebinding protection can be bypassed by using the “localhost6” domain. As long as the attacker uses the “localhost6” domain, they can still apply the attack described in CVE-2018-7160.
📍 영향받는 시스템
Node.js 10.24.0 미만, 12.21.0 미만, 14.16.0 미만, 15.10.0 미만 버전
⚔️ 공격 벡터
DNS 서버를 제어하거나 응답을 위조하여 'localhost6' 도메인을 공격자의 서버로 리바인딩하는 방식
🛡️ 대응 방법
Node.js를 취약점이 해결된 최신 버전(10.24.0, 12.21.0, 14.16.0, 15.10.0 이상)으로 업데이트
🔧 검증 코드
명령어 실행 결과로 버전 번호가 출력되면 취약한 버전을 사용 중인 것이며, 아무것도 출력되지 않으면 안전한 버전입니다.
node -v | grep -E 'v(10\.(?!(24|.*))|12\.(?!(21|.*))|14\.(?!(16|.*))|15\.(?!(10|.*)))'