🇰🇷 한글 설명
리눅스 커널의 BPF(Berkeley Packet Filter) 구성 요소에서 bprintf 스타일의 헬퍼 함수가 특정 형식 문자열(%p%)을 적절히 거부하지 못하는 취약점이 발견되었습니다. 이로 인해 런타임 중에 커널 경고(Kernel Warning)가 발생할 수 있습니다.
💡 쉬운 설명
리눅스 운영체제의 핵심 기능 중 하나에서 잘못된 글자 형식을 입력했을 때 이를 걸러내지 못하는 문제가 있습니다. 이로 인해 시스템에 경고 메시지가 뜨거나 예기치 않은 동작이 발생할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
bpf: Reject %p% format string in bprintf-like helpers
static const char fmt[] = "%p%";
bpf_trace_printk(fmt, sizeof(fmt));
The above BPF program isn't rejected and causes a kernel warning at
runtime:
Please remove unsupported %\x00 in format string
WARNING: CPU: 1 PID: 7244 at lib/vsprintf.c:2680 format_decode+0x49c/0x5d0
This happens because bpf_bprintf_prepare skips over the second %,
detected as punctuation, while processing %p. This patch fixes it by
not skipping over punctuation. %\x00 is then processed in the next
iteration and rejected.
📍 영향받는 시스템
BPF 기능을 사용하는 리눅스 커널 버전
⚔️ 공격 벡터
특수하게 조작된 형식 문자열(%p%)을 포함하는 BPF 프로그램을 로드하여 커널 경고 유도
🛡️ 대응 방법
해당 취약점이 수정된 최신 리눅스 커널 버전으로 업데이트
🔧 검증 코드
출력된 커널 버전을 확인하여 해당 취약점이 패치된 최신 보안 업데이트 버전인지 확인