🔍 CVE-2024-26885

7.8
CVSS Score
HIGH
2024-04-17
2026-10-15 01:17
✅ 완료

🇰🇷 한글 설명

리눅스 커널의 BPF DEVMAP_HASH에서 32비트 아키텍처의 오버플로우 취약점. 해시 버킷 수를 계산할 때 max_entries 값을 2의 거듭제곱으로 라운드업하는 과정에서 32비트 정수 오버플로우 발생 가능. Syzbot에 의해 arm32에서 크래시로 입증됨.

💡 쉬운 설명

리눅스 커널의 네트워크 관련 기능에서 매우 큰 값을 입력할 때 계산 오류가 발생하여 시스템이 멈출 수 있습니다. 주로 32비트 컴퓨터에 영향을 줍니다.

🇺🇸 원문 (English)

In the Linux kernel, the following vulnerability has been resolved: bpf: Fix DEVMAP_HASH overflow check on 32-bit arches The devmap code allocates a number hash buckets equal to the next power of two of the max_entries value provided when creating the map. When rounding up to the next power of two, the 32-bit variable storing the number of buckets can overflow, and the code checks for overflow by checking if the truncated 32-bit value is equal to 0. However, on 32-bit arches the rounding up itself can overflow mid-way through, because it ends up doing a left-shift of 32 bits on an unsigned long value. If the size of an unsigned long is four bytes, this is undefined behaviour, so there is no guarantee that we'll end up with a nice and tidy 0-value at the end. Syzbot managed to turn this into a crash on arm32 by creating a DEVMAP_HASH with max_entries > 0x80000000 and then trying to update it. Fix this by moving the overflow check to before the rounding up operation.

📍 영향받는 시스템

Linux kernel (모든 버전, 특히 32비트 아키텍처: ARM32, x86-32)

⚔️ 공격 벡터

로컬 공격자가 DEVMAP_HASH BPF 맵을 max_entries > 0x80000000으로 생성한 후 업데이트 시도

🛡️ 대응 방법

리눅스 커널을 패치된 버전으로 업데이트 (오버플로우 체크를 라운드업 전으로 이동하는 커널 패치 적용)

🔧 검증 코드

시스템 아키텍처가 arm 또는 x86_64/i686이고 커널 버전을 확인합니다. 2024년 초 이후의 커널 버전은 패치된 것으로 간주

Shell / Script
uname -m | grep -E 'arm|x86_64|i686' && uname -r

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

💻 영향받는 소프트웨어

Linux Kernel