中危 mm/damon/dbgfs:修复“dbgfs_target_ids_write()”中的“struct pid”泄漏 (CVE-2021-46937)

CVE编号

CVE-2021-46937

利用情况

暂无

补丁情况

官方补丁

披露时间

2024-02-27
漏洞描述
In the Linux kernel, the following vulnerability has been resolved:

mm/damon/dbgfs: fix 'struct pid' leaks in 'dbgfs_target_ids_write()'

DAMON debugfs interface increases the reference counts of 'struct pid's
for targets from the 'target_ids' file write callback
('dbgfs_target_ids_write()'), but decreases the counts only in DAMON
monitoring termination callback ('dbgfs_before_terminate()').

Therefore, when 'target_ids' file is repeatedly written without DAMON
monitoring start/termination, the reference count is not decreased and
therefore memory for the 'struct pid' cannot be freed. This commit
fixes this issue by decreasing the reference counts when 'target_ids' is
written.
解决建议
建议您更新当前系统或软件至最新版,完成漏洞的修复。
受影响软件情况
# 类型 厂商 产品 版本 影响面
1
运行在以下环境
系统 debian_10 linux * Up to
(excluding)
4.19.304-1
运行在以下环境
系统 debian_12 linux * Up to
(excluding)
5.15.15-1
运行在以下环境
系统 linux linux_kernel * From
(including)
5.15.0
Up to
(excluding)
5.15.13
阿里云评分
5.0
  • 攻击路径
    本地
  • 攻击复杂度
    困难
  • 权限要求
    管控权限
  • 影响范围
    有限影响
  • EXP成熟度
    未验证
  • 补丁情况
    官方补丁
  • 数据保密性
    无影响
  • 数据完整性
    无影响
  • 服务器危害
    无影响
  • 全网数量
    N/A
CWE-ID 漏洞类型
CWE-668 将资源暴露给错误范围
阿里云安全产品覆盖情况