v1
2026-08-02
崩溃转储前擦除机密内存 · v1
新增 CONFIG_CRASH_ZEROIZE,在 kdump 前定向擦除密钥等秘密数据,首批支持内核 keyring 和 secretmem。
原始补丁链接
子 Patch(4)
1/4
of/kexec: fix typo in comment (usable-memory-range)
修正 drivers/of/kexec.c 中 usable-memory-range 相关注释的拼写错误;仅改动注释文本,不涉及任何代码逻辑,属于 kexec 设备树处理路径的清理。
2/4
kexec: add CRASH_ZEROIZE to wipe secrets before kdump
新增 CRASH_ZEROIZE 原子通知链 crash_zeroize_notifier_list,在 __crash_kexec() 后期、其他 CPU 停止后调用,使持有密钥的子系统清除内存;回调不得等待锁。
3/4
mm/secretmem: zeroize secret pages before kdump
secretmem 注册 CRASH_ZEROIZE 通知器,在 kdump 前清除 secretmem folio;因其他 CPU 已停止,可无锁遍历 xarray,s_inode_list_lock 仅 trylock,尽力而为。
4/4
security/keys: zeroize key payloads before kdump
When CONFIG_CRASH_ZEROIZE is set, try to erase key payloads on panic before jumping to the kdump kernel. CRASH_ZEROIZE notifiers run during panic() with other CPUs stopped and preemption disabled. In