🇰🇷 한글 설명
Linux 커널의 BPF(Berkeley Packet Filter) 구성 요소에서 bpf_rb_root를 해제할 때 RB 노드의 연결 상태가 제대로 초기화되지 않는 취약점입니다. 이로 인해 메모리 재사용 시 잘못된 소유권 확인이 발생하여 커널 메모리 손상이나 비정상적인 동작을 유발할 수 있습니다.
💡 쉬운 설명
컴퓨터의 메모리를 정리하는 과정에서 흔적이 남아서, 나중에 같은 메모리 자리를 다시 쓸 때 예전 데이터와 충돌이 일어나는 문제입니다. 이 충돌을 이용하면 시스템의 보안을 무너뜨릴 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
bpf: Clear rb node linkage when freeing bpf_rb_root
bpf_rb_root_free() detaches the root by copying the current rb_root_cached
and then replacing the live root with RB_ROOT_CACHED. It then walks the
copied root and drops each object contained in the tree.
This leaves the rb node state intact while dropping the object. If the
object is refcounted and survives the drop, its bpf_rb_node_kern still
contains an owner pointer to the freed root and stale rb tree linkage. If
a later bpf_rb_root allocation reuses the same address, bpf_rbtree_remove()
can incorrectly pass the owner check and call rb_erase_cached() on a node
whose rb pointers belong to the old tree.
Mirror the list draining behavior by marking nodes as busy while the root
is being detached, then clear the rb node and release the owner before
dropping the containing object. This makes surviving nodes unowned and
safe to reject from remove or accept for a later add.
📍 영향받는 시스템
Linux Kernel (BPF subsystem 사용 환경)
⚔️ 공격 벡터
특수하게 조작된 BPF 프로그램을 실행하여 메모리 해제 및 재할당 과정을 유도함으로써 커널 메모리 오류 유발
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이후인지 확인