🇰🇷 한글 설명
Linux 커널의 bpf_btf_find_by_name_kind() 함수가 sleepable 상태로 표시되지 않아 발생하는 취약점입니다. 이로 인해 잠들 수 없는 컨텍스트(예: BPF 타이머 콜백)에서 파일 디스크립터 할당을 시도할 때 시스템 충돌이나 예기치 않은 동작이 발생할 수 있습니다.
💡 쉬운 설명
컴퓨터가 잠시 쉬어야 하는 작업을 수행할 수 없는 상황에서 강제로 쉬는 동작을 시도하여 시스템이 멈추거나 오류가 날 수 있는 문제입니다. 이를 방지하기 위해 해당 작업이 언제 가능한지 명확히 구분하도록 수정되었습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
bpf: Mark bpf_btf_find_by_name_kind() as sleepable
When bpf_btf_find_by_name_kind() finds a type in module BTF, it
returns a new BTF object fd through __btf_new_fd(). This reaches
anon_inode_getfd(), which can sleep while allocating or expanding the
current task fd table.
The helper prototype does not set might_sleep, so the verifier allows
the helper in non-sleepable contexts such as BPF timer callbacks. The
fd allocation can then sleep in softirq context and install the fd into
the interrupted task.
Mark the helper as sleepable. This preserves calls from the main body
of a sleepable syscall program while rejecting calls from its
non-sleepable regions.
📍 영향받는 시스템
Linux kernel (bpf 관련 기능이 활성화된 버전)
⚔️ 공격 벡터
비잠자기(non-sleepable) 컨텍스트에서 BPF 헬퍼 함수를 호출하여 커널의 파일 디스크립터 할당 프로세스를 트리거함
🛡️ 대응 방법
해당 취약점이 해결된 최신 Linux 커널 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 패치가 적용된 보안 업데이트 버전인지 확인