🇰🇷 한글 설명
Linux 커널 maple_tree의 mas_preallocate() 함수에서 MA_STATE_PREALLOC 플래그가 잘못 처리되어 메모리 할당 요청이 무시되고 WARN_ON() 및 널 포인터 역참조가 발생할 수 있습니다. 드라이버가 VMA 플래그를 변경할 때 mmap_region()에서 VMA 병합 재시도 시 문제가 발생합니다.
💡 쉬운 설명
Linux 커널 메모리 할당 시스템에서 특정 플래그 오류로 인해 필요한 메모리 할당이 무시될 수 있습니다. 이는 시스템 충돌을 초래할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
maple_tree: fix MA_STATE_PREALLOC flag in mas_preallocate()
Temporarily clear the preallocation flag when explicitly requesting
allocations. Pre-existing allocations are already counted against the
request through mas_node_count_gfp(), but the allocations will not happen
if the MA_STATE_PREALLOC flag is set. This flag is meant to avoid
re-allocating in bulk allocation mode, and to detect issues with
preallocation calculations.
The MA_STATE_PREALLOC flag should also always be set on zero allocations
so that detection of underflow allocations will print a WARN_ON() during
consumption.
User visible effect of this flaw is a WARN_ON() followed by a null pointer
dereference when subsequent requests for larger number of nodes is
ignored, such as the vma merge retry in mmap_region() caused by drivers
altering the vma flags (which happens in v6.6, at least)
📍 영향받는 시스템
Linux kernel v6.6 ~ v6.10 및 maple_tree 기반 커널
⚔️ 공격 벡터
로컬 사용자가 VMA 병합 또는 대량 노드 할당을 유발하는 시스템 호출 실행
🛡️ 대응 방법
Linux 커널을 최신 안정화 버전(v6.10.x 이상)으로 업데이트 또는 공식 maple_tree 패치 적용
🔧 검증 코드
커널 버전이 6.6~6.10 범위면 영향 받을 수 있으며 배포판의 백포트 패치 여부 확인 필요
uname -r | awk -F. '{if ($1==6 && $2>=6 && $2<=10) print "Potentially vulnerable"; else print "Likely patched"}'