🇰🇷 한글 설명
Linux 커널의 BPF 기능에서 bpf_cpumask_populate() 함수가 읽기 전용 cpumask 포인터를 쓰기 가능한 대상으로 잘못 수용할 수 있는 취약점이 발견되었습니다. 이로 인해 검증기(verifier)가 읽기 전용 메모리 영역에 대한 쓰기 작업을 허용할 수 있는 보안 결함이 존재합니다.
💡 쉬운 설명
컴퓨터의 중요한 정보를 보호하기 위해 '읽기 전용'으로 설정된 영역이 있는데, 특정 명령어를 통해 이 영역을 강제로 수정할 수 있는 허점이 발견되었습니다. 이를 통해 공격자가 시스템의 핵심 설정을 변경하거나 권한을 탈취할 위험이 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
bpf: Require a BPF cpumask for bpf_cpumask_populate()
bpf_cpumask_populate() writes to its destination with bitmap_copy(), but
the destination is typed as struct cpumask *. That allows the verifier to
accept borrowed cpumask pointers returned by read-only kfuncs, such as
scx_bpf_get_online_cpumask(), as a writable destination.
Make the destination a struct bpf_cpumask * so populate follows the same
ownership rule as the other mutating cpumask kfuncs. Query kfuncs continue
to accept const struct cpumask * inputs.
📍 영향받는 시스템
Linux Kernel (BPF 기능이 활성화된 버전)
⚔️ 공격 벡터
BPF 프로그램을 통해 읽기 전용 kfunc로부터 반환된 cpumask 포인터를 bpf_cpumask_populate()의 쓰기 대상으로 전달하여 메모리 오염 유도
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 bpf_cpumask_populate()의 목적지 타입을 수정해야 함
🔧 검증 코드
출력된 커널 버전을 확인하여 해당 취약점이 해결된 최신 패치 버전인지 확인하십시오.