🇰🇷 한글 설명
Linux 커널의 dm-pcache 구성 요소에서 kset key_num 및 세그먼트 내부 경계 검증 미흡으로 인한 취약점이 발견되었습니다. 공격자가 조작된 캐시 장치를 제공할 경우, 경계를 벗어난 읽기(Out-of-bounds read)가 발생하여 인접한 영구 메모리의 데이터가 사용자 공간으로 유출될 수 있습니다.
💡 쉬운 설명
컴퓨터의 메모리 관리 기능에서 데이터의 범위를 제대로 확인하지 않아 발생하는 문제입니다. 이를 통해 공격자가 허용되지 않은 메모리 영역의 정보를 몰래 읽어갈 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
dm-pcache: validate kset key_num and intra-segment bounds
Two more fields decoded from the cache device go unbounded. The kset
key_num drives cache_kset_crc() and the replay loop in cache_replay(),
the writeback worker and the GC worker, but only the magic and a
fixed-seed CRC are checked first, so a non-last kset whose key_num exceeds
the PCACHE_KSET_KEYS_MAX buffer reads past its end before the CRC compare.
A key's intra-segment offset and length in cache_key_decode() are taken
verbatim, so a key running past its segment is replayed into the cache
tree and the data CRC check and every later read hit then copy adjacent
persistent memory into the caller's bio -- an out-of-bounds read that
leaks to user space. Both fields are controlled by whoever supplies the
cache device (CAP_SYS_ADMIN); the CRC seed is public.
Add kset_onmedia_valid() to bound key_num before any kset read, and
reject a key whose offset plus length, computed in 64 bits, exceeds the
segment data_size. Valid metadata is unaffected.
📍 영향받는 시스템
Linux Kernel (dm-pcache 모듈을 사용하는 시스템)
⚔️ 공격 벡터
CAP_SYS_ADMIN 권한을 가진 사용자가 조작된 캐시 장치를 공급하여 경계 검증을 우회함
🛡️ 대응 방법
dm-pcache의 kset key_num 경계 검증 및 세그먼트 오프셋/길이 검증 로직이 포함된 최신 커널로 업데이트
🔧 검증 코드
출력된 커널 버전이 해당 취약점이 패치된 최신 보안 업데이트 버전인지 확인