🔍 CVE-2025-38255

5.5
CVSS Score
MEDIUM
2025-07-09
2026-11-05 21:18
✅ 완료

🇰🇷 한글 설명

Linux 커널의 lib/group_cpus 모듈에서 group_cpus_evenly() 함수가 numgrps를 0으로 받을 때 kcalloc()이 반환하는 ZERO_SIZE_PTR을 역참조하여 NULL 포인터 역참조 커널 패닉이 발생하는 문제입니다. 수정은 함수 시작 시 numgrps를 먼저 검사하여 0이면 즉시 NULL을 반환하도록 합니다. SMP 및 non-SMP 버전 모두 수정되었습니다.

💡 쉬운 설명

CPU 그룹을 나누는 커널 함수에서 그룹 수가 0일 때 잘못된 메모리 주소를 사용하여 시스템이 멈추는 버그입니다. 그룹 수가 0인지 먼저 확인하도록 고쳐서 이 문제를 해결했습니다.

🇺🇸 원문 (English)

In the Linux kernel, the following vulnerability has been resolved: lib/group_cpus: fix NULL pointer dereference from group_cpus_evenly() While testing null_blk with configfs, echo 0 > poll_queues will trigger following panic: BUG: kernel NULL pointer dereference, address: 0000000000000010 Oops: Oops: 0000 [#1] SMP NOPTI CPU: 27 UID: 0 PID: 920 Comm: bash Not tainted 6.15.0-02023-gadbdb95c8696-dirty #1238 PREEMPT(undef) Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.1-2.fc37 04/01/2014 RIP: 0010:__bitmap_or+0x48/0x70 Call Trace: <TASK> __group_cpus_evenly+0x822/0x8c0 group_cpus_evenly+0x2d9/0x490 blk_mq_map_queues+0x1e/0x110 null_map_queues+0xc9/0x170 [null_blk] blk_mq_update_queue_map+0xdb/0x160 blk_mq_update_nr_hw_queues+0x22b/0x560 nullb_update_nr_hw_queues+0x71/0xf0 [null_blk] nullb_device_poll_queues_store+0xa4/0x130 [null_blk] configfs_write_iter+0x109/0x1d0 vfs_write+0x26e/0x6f0 ksys_write+0x79/0x180 __x64_sys_write+0x1d/0x30 x64_sys_call+0x45c4/0x45f0 do_syscall_64+0xa5/0x240 entry_SYSCALL_64_after_hwframe+0x76/0x7e Root cause is that numgrps is set to 0, and ZERO_SIZE_PTR is returned from kcalloc(), and later ZERO_SIZE_PTR will be deferenced. Fix the problem by checking numgrps first in group_cpus_evenly(), and return NULL directly if numgrps is zero. [[email protected]: also fix the non-SMP version]

📍 영향받는 시스템

패치 이전의 Linux 커널 (수정 커밋이 포함되지 않은 6.x 계열 등 배포판별 커널 버전)

⚔️ 공격 벡터

일반 사용자가 null_blk 설정에서 poll_queues를 0으로 바꾸는 등 특정 조건에서 트리거되며, 로컬에서 시스템 패닉(서비스 거부)을 유발할 수 있습니다.

🛡️ 대응 방법

배포판 벤더가 제공하는 최신 커널 패키지로 업데이트하고 재부팅하세요.

🔧 검증 코드

출력된 커널 버전을 배포판 보안 공지(CVE-2025-38255 수정 버전)와 비교하여 수정된 커널인지 확인하세요. 수정 버전 이상이면 패치된 것입니다.

Shell / Script
uname -r

📊 CVSS Vector String

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

💻 영향받는 소프트웨어

Linux Kernel