🇰🇷 한글 설명
Undici의 deduplicate 인터셉터가 활성화된 경우, 중복된 요청에 대한 응답 데이터를 메모리에 계속 누적하여 자원을 과도하게 소비하는 취약점입니다. 공격자가 대용량 또는 청크 단위의 응답을 생성하는 엔드포인트를 이용해 동일한 요청을 동시에 보내면 메모리 부족(OOM)으로 인해 프로세스가 종료될 수 있습니다.
💡 쉬운 설명
똑같은 요청을 여러 번 보낼 때 서버가 응답 내용을 메모리에 너무 많이 쌓아두어 컴퓨터가 멈추게 만드는 문제입니다. 공격자가 아주 큰 데이터를 계속 보내면 메모리가 꽉 차서 프로그램이 강제로 꺼질 수 있습니다.
🇺🇸 원문 (English)
This is an uncontrolled resource consumption vulnerability (CWE-400) that can lead to Denial of Service (DoS).
In vulnerable Undici versions, when interceptors.deduplicate() is enabled, response data for deduplicated requests could be accumulated in memory for downstream handlers. An attacker-controlled or untrusted upstream endpoint can exploit this with large/chunked responses and concurrent identical requests, causing high memory usage and potential OOM process termination.
Impacted users are applications that use Undici’s deduplication interceptor against endpoints that may produce large or long-lived response bodies.
PatchesThe issue has been patched by changing deduplication behavior to stream response chunks to downstream handlers as they arrive (instead of full-body accumulation), and by preventing late deduplication when body streaming has already started.
Users should upgrade to the first official Undici (and Node.js, where applicable) releases that include this patch.
📍 영향받는 시스템
interceptors.deduplicate() 기능이 활성화된 Undici 라이브러리 사용 애플리케이션
⚔️ 공격 벡터
공격자가 제어 가능한 엔드포인트에 대용량 응답을 생성하도록 유도한 뒤, 동일한 요청을 동시에 여러 번 전송하여 메모리 점유율을 높임
🛡️ 대응 방법
패치가 적용된 최신 버전의 Undici 및 Node.js로 업데이트하여 응답 데이터를 스트림 방식으로 처리하도록 변경
🔧 검증 코드
출력된 Undici의 버전을 확인하여 패치가 적용된 최신 버전인지 대조함