🇰🇷 한글 설명
Linux 커널의 net/bpf 서브시스템에서 xdp_master_redirect() 함수가 활성화된 상태에서, 아직 활성화되지 않은(down) 본딩(bonding) 장치를 참조할 때 발생하는 Null 포인터 역참조 취약점입니다. 이로 인해 시스템 커널 패닉이 발생하여 서비스 거부(DoS) 상태에 빠질 수 있습니다.
💡 쉬운 설명
네트워크 장치를 연결하는 과정에서 설정이 채 끝나기도 전에 특정 기능이 작동하여 컴퓨터 시스템이 갑자기 멈추는 문제입니다. 네트워크 설정이 불완전한 상태에서 잘못된 메모리 주소를 건드려 발생하는 오류입니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net, bpf: fix null-ptr-deref in xdp_master_redirect() for down master
syzkaller reported a kernel panic in bond_rr_gen_slave_id() reached via
xdp_master_redirect(). Full decoded trace:
https://syzkaller.appspot.com/bug?extid=80e046b8da2820b6ba73
bond_rr_gen_slave_id() dereferences bond->rr_tx_counter, a per-CPU
counter that bonding only allocates in bond_open() when the mode is
round-robin. If the bond device was never brought up, rr_tx_counter
stays NULL.
The XDP redirect path can still reach that code on a bond that was
never opened: bpf_master_redirect_enabled_key is a global static key,
so as soon as any bond device has native XDP attached, the
XDP_TX -> xdp_master_redirect() interception is enabled for every
slave system-wide. The path xdp_master_redirect() ->
bond_xdp_get_xmit_slave() -> bond_xdp_xmit_roundrobin_slave_get() ->
bond_rr_gen_slave_id() then runs against a bond that has no
rr_tx_counter and crashes.
Fix this in the generic xdp_master_redirect() by refusing to call into
the master's ->ndo_xdp_get_xmit_slave() when the master device is not
up. IFF_UP is only set after ->ndo_open() has successfully returned,
so this reliably excludes masters whose XDP state has not been fully
initialized. Drop the frame with XDP_ABORTED so the exception is
visible via trace_xdp_exception() rather than silently falling through.
This is not specific to bonding: any current or future master that
defers XDP state allocation to ->ndo_open() is protected.
📍 영향받는 시스템
Linux kernel (bonding 및 XDP 기능이 활성화된 환경)
⚔️ 공격 벡터
XDP(eXpress Data Path)가 활성화된 환경에서 초기화되지 않은 본딩 장치로 트래픽을 유도하여 커널 패닉 유발
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 xdp_master_redirect()의 장치 상태 확인 로직을 적용해야 함
🔧 검증 코드
출력된 커널 버전을 확인하여 해당 취약점이 수정된 최신 패치 버전인지 확인합니다.