🔍 CVE-2026-12522

8.8
CVSS Score
HIGH
2026-08-19
2026-08-26 16:59
✅ 완료

🇰🇷 한글 설명

HL7800 셀룰러 모뎀 드라이버의 +CGCONTRDP 응답 처리 과정에서 PDP 컨텍스트 파라미터를 파싱할 때 스택 버퍼 오버플로우가 발생합니다. 공격자가 조작된 네트워크 응답을 보내면 고정된 크기의 버퍼를 초과하여 데이터를 쓰게 되어 시스템 충돌이나 제어 흐름 탈취가 가능합니다.

💡 쉬운 설명

가짜 기지국이 모뎀에 잘못된 정보를 보내면 모뎀 내부의 메모리가 넘쳐흐르는 보안 약점입니다. 이를 통해 해커가 기기의 동작을 멈추거나 기기를 원격으로 조종할 위험이 있습니다.

🇺🇸 원문 (English)

The HL7800 cellular modem driver's +CGCONTRDP: response handler on_cmd_atcmdinfo_ipaddr() in drivers/modem/vendor_standalone/hl7800.c parses the PDP-context dynamic parameters (local address, subnet mask, gateway, and DNS servers) that the cellular network assigns to the device. The response is linearized into a 256-byte stack buffer, after which each address field length is computed from comma/.; in the network-supplied data and used directly as the length argument to strncpy() into the fixed 64-byte stack buffer temp_addr_str (and the 16-byte iface_ctx.dns_v4_string). Because the field length is derived from attacker-controlled; and was not bounded against the destination buffer, a single field can be far larger than 64 bytes. A malicious or impersonated cellular network (for example a rogue base station) can return a crafted +CGCONTRDP response with an overlong address field, causing strncpy() to write past temp_addr_str on the modem worker thread's stack, plus an out-of-bounds NUL write at temp_addr_str[addr_len]. No device-side privileges or user interaction are required: the device itself issues the AT+CGCONTRDP=1 query during normal network attach and parses whatever the network returns. The overflow corrupts adjacent stack memory in supervisor context, yielding at minimum a remotely triggerable crash and potentially control-flow hijacking on targets without stack protection. The fix bounds every field length against its destination buffer (temp_addr_str and dns_v4_string) before each copy, rejecting overlong fields.

📍 영향받는 시스템

HL7800 cellular modem driver (drivers/modem/vendor_standalone/hl7800.c 포함 버전)

⚔️ 공격 벡터

조작된 +CGCONTRDP 응답을 보내는 가짜 기지국(Rogue Base Station)을 통한 원격 공격

🛡️ 대응 방법

모든 필드 길이를 대상 버퍼 크기에 맞춰 제한하도록 드라이버 소스 코드를 수정하고 업데이트합니다.

🔧 검증 코드

해당 함수 내에서 strncpy() 호출 전 필드 길이를 목적지 버퍼 크기와 비교하여 검증하는 로직이 있는지 확인합니다.

Shell / Script
grep -r "on_cmd_atcmdinfo_ipaddr" drivers/modem/vendor_standalone/hl7800.c

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

💻 영향받는 소프트웨어

Spring Cloud Gateway Server