IPBUF安全漏洞报告
English
CVE-2026-43124 CVSS 5.5 中危

CVE-2026-43124 Linux内核pstore空指针解引用漏洞

披露日期: 2026-05-06
来源: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

漏洞信息

漏洞编号
CVE-2026-43124
漏洞类型
空指针解引用
CVSS评分
5.5 中危
攻击向量
本地 (AV:L)
认证要求
低权限 (PR:L)
用户交互
无需交互 (UI:N)
影响产品
Linux Kernel

相关标签

Linux Kernelpstore空指针解引用DoS本地漏洞

漏洞概述

Linux内核的pstore模块中的ram_core组件存在一个逻辑漏洞。在persistent_ram_vmap函数中,当vmap()调用失败返回NULL时,如果偏移量不为零,代码错误地将偏移值加到NULL指针上,导致返回了一个非空的无效地址。这导致上层函数误判映射成功,后续访问该无效地址会引发系统崩溃。

技术细节

该漏洞位于Linux内核的fs/pstore/ram_core.c文件中。问题出在persistent_ram_vmap()函数的实现逻辑里。该函数调用vmap()尝试建立虚拟地址映射,正常情况下失败应返回NULL。然而,代码直接返回了`vaddr + offset_in_page(start)`。当vmap()失败(vaddr为NULL)且offset_in_page(start)不为0时,指针运算结果变成了一个非NULL的无效地址(等于偏移量的数值)。调用者persistent_ram_buffer_map()检查返回值不为NULL,便认为映射成功,继续使用该指针。当后续代码访问prz->buffer时,会触发内核态的非法内存访问,导致Kernel Panic。攻击者需具备本地低权限,通过特定的内存压力或触发pstore记录机制可利用此漏洞造成拒绝服务。

攻击链分析

STEP 1
步骤1:获取本地访问权限
攻击者获得目标系统的本地低权限用户访问权限。
STEP 2
步骤2:制造内存压力
攻击者运行程序消耗系统内存资源,增加内核vmap()调用失败的概率。
STEP 3
步骤3:触发漏洞代码路径
攻击者触发pstore/ram_core相关的操作(如写入日志),调用persistent_ram_vmap函数。
STEP 4
步骤4:触发逻辑错误
vmap()返回NULL,但由于offset存在,函数返回非NULL指针,上层误判成功。
STEP 5
步骤5:系统崩溃
内核访问无效内存地址,导致系统崩溃或重启,实现拒绝服务攻击。

PoC / 利用代码

⚠️ 仅供安全研究
以下代码仅用于安全研究和授权测试,未经授权使用属于违法行为。
PoC
/* * Conceptual PoC for CVE-2026-43124 * This demonstrates the logic flaw in persistent_ram_vmap. * Requires a vulnerable kernel build. */ #include <stdio.h> #include <stdlib.h> #include <fcntl.h> #include <unistd.h> int main() { int fd; // Attempt to interact with pstore (ramoops) // Note: This requires CONFIG_PSTORE_RAM enabled and proper setup. fd = open("/dev/pmsg0", O_RDWR); if (fd < 0) { perror("Failed to open pmsg0. Device might not exist."); return 1; } // In a real scenario, one would need to induce memory pressure // to cause vmap() to fail inside the kernel. // Then triggering a write might hit the incorrect return path. char *trigger_data = "Crash trigger data"; write(fd, trigger_data, 20); printf("Data written. If vmap failed and offset != 0, kernel may crash on access.\n"); close(fd); return 0; }

影响范围

Linux Kernel(具体受影响版本请参考Git提交记录)

防御指南

临时缓解措施
如果无法立即升级内核,建议禁用内核中的pstore模块(特别是ramoops),以阻断攻击路径,直到系统更新完成。

参考链接

快速导航: 前沿安全 最新收录域名列表 最新威胁情报列表 最新网站排名列表 最新工具资源列表 最新CVE漏洞列表