🇰🇷 한글 설명
Axios 1.7.0부터 1.20.0 버전 사이에서 fetch 어댑터가 원래의 fetchOptions를 사용하여 fetch를 호출할 때 발생하는 보안 취약점입니다. 프로토타입 오염(Prototype Pollution)을 통해 Object.prototype.headers가 조작되면, 정화된 요청 헤더 대신 공격자가 제어하는 헤더가 적용되어 권한 탈취나 메타데이터 서비스 접근이 가능해질 수 있습니다.
💡 쉬운 설명
웹 통신 도구인 Axios의 특정 버전에서 데이터 처리 방식의 허점으로 인해, 공격자가 몰래 가짜 정보를 끼워 넣을 수 있는 문제입니다. 이를 통해 사용자의 로그인 정보가 유출되거나 시스템 설정이 변경될 위험이 있습니다.
🇺🇸 원문 (English)
Axios is a promise-based HTTP client for the browser and Node.js. From 1.7.0 until 1.20.0, the fetch adapter constructs a Request with sanitized resolvedOptions but then calls fetch with the original fetchOptions. A separate same-process prototype-pollution flaw populates Object.prototype.headers so fetchOptions.headers resolves through inheritance. The inherited fetchOptions.headers value overrides the sanitized Request headers through the second argument to fetch after Request construction. Attacker-controlled request headers can alter authorization, caching, metadata-service access, or application-specific behavior. This issue is fixed in version 1.20.0.
📍 영향받는 시스템
Axios versions 1.7.0 to 1.20.0
⚔️ 공격 벡터
프로토타입 오염을 이용해 Object.prototype.headers를 조작한 후, Axios의 fetch 호출 시 조작된 헤더가 적용되도록 유도
🛡️ 대응 방법
Axios를 1.20.0 이상의 최신 버전으로 업데이트하십시오.
🔧 검증 코드
출력된 결과의 버전이 1.7.0 이상 1.20.0 미만인지 확인하십시오.
npm list axios | grep axios