🇰🇷 한글 설명
Linux 커널의 ice 드라이버에서 ice_parser_profile_init 함수가 유효 범위를 벗어난 ptype 값을 검증하지 않아 발생하는 취약점입니다. 악의적인 가상 기능(VF)이 범위를 초과하는 ptype 값을 제공할 경우, 비트맵 범위를 벗어난 메모리 쓰기가 발생하여 커널 페이지 폴트 및 시스템 충돌을 유발할 수 있습니다.
💡 쉬운 설명
네트워크 장치 드라이버가 잘못된 번호의 데이터를 처리하려다 컴퓨터의 핵심 시스템(커널) 영역을 건드려 시스템이 멈추거나 오류가 발생하는 문제입니다. 공격자가 조작된 신호를 보내 시스템을 강제로 다운시킬 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
ice: reject out-of-range ptype in ice_parser_profile_init
set_bit(rslt->ptype, prof->ptypes) operates on a DECLARE_BITMAP of
ICE_FLOW_PTYPE_MAX (1024) bits. Nothing prevents a malicious VF from
providing ptype >= 1024 through VIRTCHNL, resulting in a write past
the end of the bitmap and a kernel page fault.
Reproduced with a custom kernel module injecting a crafted
VIRTCHNL_OP_ADD_RSS_CFG on E810-C QSFP (8086:1592),
FW 4.91 0x800214af 1.3909.0, ICE COMMS DDP 1.3.53.0,
kernel 7.1.0-rc1.
crash_parser: ice_parser_profile_init @ ffffffffc0d61b60
crash_parser: setting ptype=0xffff (max valid=1023)
crash_parser: calling ice_parser_profile_init -- expect OOB crash!
BUG: kernel NULL pointer dereference, address: 0000000000000000
Oops: Oops: 0002 [#1] SMP NOPTI
CPU: 56 UID: 0 PID: 165011 Comm: insmod Kdump: loaded Tainted: G S U OE 7.1.0-rc1 #1
Hardware name: Intel Corporation S2600BPB/S2600BPB
RIP: 0010:ice_parser_profile_init+0x2d/0x1d0 [ice]
Call Trace:
<TASK>
? __pfx_ice_parser_profile_init+0x10/0x10 [ice]
crash_init+0x127/0xff0 [crash_parser]
do_one_initcall+0x45/0x310
do_init_module+0x64/0x270
init_module_from_file+0xcc/0xf0
idempotent_init_module+0x17b/0x280
__x64_sys_finit_module+0x6e/0xe0
Bail out early with -EINVAL when ptype is out of range.
📍 영향받는 시스템
Linux kernel (ice driver 사용 환경, 특히 E810-C QSFP 하드웨어 관련 시스템)
⚔️ 공격 벡터
VIRTCHNL을 통해 조작된 VIRTCHNL_OP_ADD_RSS_CFG 명령을 전달하여 범위를 벗어난 ptype 값 주입
🛡️ 대응 방법
ice_parser_profile_init 함수에서 ptype 값이 ICE_FLOW_PTYPE_MAX(1024)를 초과하는지 검사하고, 범위를 벗어나면 -EINVAL를 반환하도록 커널 패치 적용
🔧 검증 코드
현재 실행 중인 커널 버전을 확인하여 취약점이 해결된 패치 버전인지 확인합니다.