🇰🇷 한글 설명
brace-expansion 라이브러리에서 특수하게 제작된 중괄호 패턴을 처리할 때 네이티브 스택이 고갈되는 취약점이 발견되었습니다. 이로 인해 Node.js 프로세스가 비정상적으로 종료되어 서비스 거부(DoS) 상태가 발생할 수 있습니다.
💡 쉬운 설명
특정한 규칙을 가진 복잡한 문자를 입력하면 프로그램이 이를 처리하다가 과부하가 걸려 멈춰버리는 문제입니다. 이로 인해 웹사이트나 서비스가 갑자기 꺼질 수 있습니다.
🇺🇸 원문 (English)
The brace-expansion library generates arbitrary strings containing a common prefix and suffix. Prior to 1.1.19, 2.1.5, 3.0.7, and 5.0.10, crafted brace patterns can exhaust the native stack in parseCommaParts because parseCommaParts recursively processes the remainder once per brace group and uses push.apply to pass every element of a very large comma-part array as a function argument. Patterns containing many comma-separated brace groups trigger the recursive path, while the large array triggers the argument-array path without deep recursion. These paths cause recursive and argument-array native stack exhaustion before max or maxLength can limit output, potentially terminating the Node.js process in a process-terminating denial of service. This issue is fixed in versions 1.1.19, 2.1.5, 3.0.7, and 5.0.10.
📍 영향받는 시스템
brace-expansion versions < 1.1.19, < 2.1.5, < 3.0.7, < 5.0.10
⚔️ 공격 벡터
악의적으로 조작된 중괄호 패턴(brace patterns)을 입력값으로 전달하여 재귀 호출 및 인자 배열 처리를 유도함
🛡️ 대응 방법
라이브러리를 수정된 버전(1.1.19, 2.1.5, 3.0.7, 5.0.10 이상)으로 업데이트하십시오.
🔧 검증 코드
출력된 결과에서 현재 설치된 brace-expansion의 버전을 확인하여 취약한 버전인지 대조합니다.