🇰🇷 한글 설명
Linux 커널의 XDP(eXpress Data Path) 구성 요소에서 zero-copy 프레임 레이아웃 처리 오류가 발견되었습니다. AF_XDP zero-copy 패킷이 cpumap을 통해 리다이렉션될 때, 패킷 데이터가 skb_shared_info 영역을 침범하거나 할당된 페이지 범위를 벗어나 메모리 오버플로우를 유발할 수 있습니다.
💡 쉬운 설명
네트워크 데이터를 아주 빠르게 처리하는 과정에서 데이터의 크기를 잘못 계산하여, 데이터가 정해진 메모리 공간을 넘쳐흐르는 보안 결함입니다. 이로 인해 시스템이 멈추거나 해커가 시스템 권한을 탈취할 위험이 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
xdp: fix zero-copy frame layout
xdp_convert_zc_to_xdp_frame() clones an XSK packet into an order-0 page
and advertises PAGE_SIZE as its frame size. It allows the copied frame
to occupy the page tail needed by skb_shared_info and records zero
headroom even when metadata separates the frame header from packet data.
An AF_XDP zero-copy packet redirected through cpumap can therefore make
the skb overlap skb_shared_info or place it beyond the allocated page.
Limit the copied layout to SKB_WITH_OVERHEAD(PAGE_SIZE) and include the
metadata length in frame headroom. Redirect callers already handle a
NULL conversion result.
BUG: KASAN: slab-out-of-bounds in skb_gro_receive
Write of size 4 at addr ffff88800cf37004 by task cpumap/1/map:1/146
Call Trace:
skb_gro_receive (net/core/gro.c:174)
udp_gro_receive (net/ipv4/udp_offload.c:812)
inet_gro_receive (net/ipv4/af_inet.c:1539)
dev_gro_receive (net/core/gro.c:515)
gro_receive_skb (net/core/gro.c:633)
cpu_map_kthread_run (kernel/bpf/cpumap.c:395)
kthread (kernel/kthread.c:436)
ret_from_fork (arch/x86/kernel/process.c:164)
ret_from_fork_asm (arch/x86/entry/entry_64.S:255)
Kernel panic - not syncing: KASAN: panic_on_warn set ...
📍 영향받는 시스템
XDP 및 AF_XDP 기능을 사용하는 Linux 커널 버전 (패치 전 버전)
⚔️ 공격 벡터
조작된 AF_XDP zero-copy 패킷을 생성하여 cpumap을 통해 리다이렉션시키는 방식
🛡️ 대응 방법
XDP zero-copy 프레임 레이아웃 수정 사항이 포함된 최신 Linux 커널로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 최신 보안 패치 버전인지 확인