🇰🇷 한글 설명
NGINX JavaScript(njs)의 XML 모듈이 libxml2의 정규화 방식과 일치하지 않게 엔티티 기반 XML 속성을 처리하는 취약점이 발견되었습니다. 이로 인해 서명 검증은 성공하지만 특정 보안 속성이 누락된 것처럼 보일 수 있어, nginx-saml 환경에서 만료 시간이나 목적지 확인을 우회할 수 있습니다.
💡 쉬운 설명
XML 문서 내의 특수 기호를 처리하는 과정에서 오류가 발생하여, 보안 검사를 통과해야 할 중요한 정보가 없는 것처럼 속일 수 있는 문제입니다. 공격자는 이를 이용해 이미 사용된 인증 정보를 다시 사용하거나 유효하지 않은 요청을 통과시킬 수 있습니다.
🇺🇸 원문 (English)
Description
NGINX JavaScript (njs) has a vulnerability where the njs XML module exposes entity-backed XML attributes inconsistently with libxml2 canonicalization. In both the built-in njs and QuickJS backends during the canonicalization process, the $attr$Name getter may return undefined for an explicitly present attribute containing an internal entity reference. The $attrs getter may return a value derived only from the first attribute child. This may allow an unauthenticated attacker that invests significant effort in obtaining a genuinely signed document to skip validation while signature verification succeeds. An nginx-saml deployment is a confirmed affected consumer when run with the built-in njs backend.
Impact
In affected signed-XML consumers, an unauthenticated attacker can cause security-relevant attributes to appear absent or truncated while signature verification succeeds. In nginx-saml, this can bypass expiry, Destination, and request-correlation checks, enabling replay or acceptance of a response outside its intended context. It does not permit signature or identity forgery, or a direct availability impact. There is no control plane exposure; this is a data plane issue only.
Note: Software versions which have reached End of Technical Support (EoTS) are not evaluated.
📍 영향받는 시스템
njs XML 모듈을 사용하는 NGINX 환경 (특히 built-in njs 백엔드를 사용하는 nginx-saml 배포판)
⚔️ 공격 벡터
내부 엔티티 참조를 포함한 조작된 XML 문서를 전송하여 서명 검증 로직을 우회함
🛡️ 대응 방법
njs 모듈을 최신 보안 패치가 적용된 버전으로 업데이트하거나, 취약한 XML 처리 로직을 점검하십시오.
🔧 검증 코드
출력 결과에서 njs 모듈의 사용 여부와 현재 설치된 버전을 확인하여 취약 버전 포함 여부를 판단합니다.
nginx -V 2>&1 | grep -i 'njs'