🇰🇷 한글 설명
Linux 커널의 libbpf에서 서명된 로더가 독점적이지 않은 메타데이터 맵을 거부하지 않아 발생하는 취약점입니다. 공격자가 호스트 환경을 제어할 경우, 맵의 독점성을 제거하여 BPF 프로그램이 해시 검증을 통과한 후 데이터를 변조할 수 있습니다.
💡 쉬운 설명
프로그램이 실행될 때 데이터가 안전한지 확인하는 과정에서, 공격자가 확인이 끝난 직후 데이터를 몰래 바꿀 수 있는 허점이 발견되었습니다. 이로 인해 보안 검사를 우회하여 악성 코드가 실행될 위험이 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
libbpf: Reject non-exclusive metadata maps in the signed loader
The loader verifies map->sha against the metadata hash in its
instructions. map->sha is calculated when BPF_OBJ_GET_INFO_BY_FD is
called on the frozen map.
While the map is frozen, the /signed loader/ must also ensure the map
is exclusive, as, without exclusivity (which a hostile host could just
omit when loading the loader), another BPF program with map access can
mutate the contents afterwards, so the check passes on stale data.
With the extra check as part of the signed loader, it now refuses to
move on with map->sha validation if the host set it up wrongly.
📍 영향받는 시스템
Linux kernel (libbpf component)
⚔️ 공격 벡터
호스트 환경에서 BPF 맵의 독점성을 제거하여 검증된 데이터가 변조되도록 유도하는 방식
🛡️ 대응 방법
Linux 커널을 최신 보안 패치가 적용된 버전으로 업데이트하여 libbpf의 독점성 확인 로직을 적용해야 합니다.
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 해결된 패치 버전 이상인지 확인합니다.