漏洞标题
net/l2tp: 修复syzbot发现的l2tp_exit_net中的警告信息
漏洞描述信息
在Linux内核中,已修复以下漏洞:
net/l2tp: 修复syzbot发现的l2tp_exit_net中的警告
在l2tp的net退出处理程序中,我们在销毁IDR之前检查其是否为空:
WARN_ON_ONCE(!idr_is_empty(&pn->l2tp_tunnel_idr));
idr_destroy(&pn->l2tp_tunnel_idr);
通过迫使idr_alloc_32中的内存分配失败,syzbot能够引发一种情况,即使IDR中没有项目,idr_is_empty也会返回false。这实际上是由于IDR的基数树仅包含内部基数树节点,从而导致idr_is_empty返回false。这些内部节点将由idr_destroy清理。
使用idr_for_each代替idr_is_empty来检查IDR是否为空,从而避免该问题。
CVSS信息
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
漏洞类别
不加限制或调节的资源分配
漏洞标题
net/l2tp: fix warning in l2tp_exit_net found by syzbot
漏洞描述信息
In the Linux kernel, the following vulnerability has been resolved:
net/l2tp: fix warning in l2tp_exit_net found by syzbot
In l2tp's net exit handler, we check that an IDR is empty before
destroying it:
WARN_ON_ONCE(!idr_is_empty(&pn->l2tp_tunnel_idr));
idr_destroy(&pn->l2tp_tunnel_idr);
By forcing memory allocation failures in idr_alloc_32, syzbot is able
to provoke a condition where idr_is_empty returns false despite there
being no items in the IDR. This turns out to be because the radix tree
of the IDR contains only internal radix-tree nodes and it is this that
causes idr_is_empty to return false. The internal nodes are cleaned by
idr_destroy.
Use idr_for_each to check that the IDR is empty instead of
idr_is_empty to avoid the problem.
CVSS信息
N/A
漏洞类别
N/A
漏洞标题
Linux kernel 安全漏洞
漏洞描述信息
Linux kernel是美国Linux基金会的开源操作系统Linux所使用的内核。 Linux kernel存在安全漏洞,该漏洞源于net/l2tp子系统中l2tp_exit_net函数中的警告问题。
CVSS信息
N/A
漏洞类别
其他