🇰🇷 한글 설명
AngularJS의 Strict Contextual Escaping(SCE) 로직 결함으로 인해 리소스 URL에 대한 SCE 정책을 우회할 수 있습니다. 이를 통해 피해자 브라우저 세션 컨텍스트에서 임의의 JavaScript가 실행될 수 있습니다. 이 결함은 정규식 매처가 전체 URL이 아닌 부분 일치를 허용하는 데서 발생합니다. AngularJS는 이미 EOL 상태이므로 패치가 제공되지 않습니다.
💡 쉬운 설명
AngularJS가 신뢰할 수 없는 웹 주소를 걸러내는 보안 검사에 허점이 있습니다. 공격자가 이 허점을 이용하면 사용자 브라우저에서 악성 스크립트를 몰래 실행시킬 수 있습니다.
🇺🇸 원문 (English)
A flaw in AngularJS' Strict Contextual Escaping (SCE) logic allows bypassing certain SCE policies for resource URLs and can lead to arbitrary JavaScript execution within the context of the victim's browser session.
SCE's purpose is to ensure that only trusted or safe values are used in certain security-sensitive contexts, such as resource URLs, including URLs that define executable JavaScript scripts, '<iframe>' documents, route templates, etc. A flaw in the logic that tries to match entire URLs against regular expression matchers can result in partial matches for certain types of regular expressions, effectively bypassing the policies and allowing the use of unsafe values as resource URLs.
This issue affects AngularJS versions greater than or equal to 1.2.0-rc.3.
Note:
The AngularJS project was already End-of-Life when this CVE was published and will not receive any updates to address this issue. For more information see the End-of-Life announcement https://docs.angularjs.org/misc/version-support-status .
📍 영향받는 시스템
AngularJS 1.2.0-rc.3 이상 버전 전체 (EOL로 패치 없음)
⚔️ 공격 벡터
공격자가 조작된 URL을 SCE 검사가 적용된 리소스 경로에 주입하여 정책을 우회하고 피해자 브라우저에서 JavaScript를 실행
🛡️ 대응 방법
AngularJS 사용을 중단하고 지원되는 프레임워크(Angular 최신 버전 등)로 마이그레이션
🔧 검증 코드
출력된 버전이 1.2.0-rc.3 이상이면 취약하며, HTML에서 angular.js 파일이 발견되면 AngularJS가 사용 중인 것이므로 마이그레이션이 필요합니다
grep -rE "\"angular\"\s*:\s*\"[^\"]*\"" package.json 2>/dev/null; grep -rl "angular.min.js\|angular.js" . --include=*.html 2>/dev/null | head -5