漏洞标题
USB:xhci:修复Etron变通方法中的无效指针解引用问题
漏洞描述信息
## 漏洞概述
在Linux内核中,已经修复了一个与USB Etron变通方案相关的空指针引用漏洞。当`enqueue`已指向段的最终链接TRB时,`enqueue + 1`会导致空指针引用问题,从而导致内核崩溃或加载一些看起来像是链接TRB的垃圾数据,最终会使真实的链接TRB被替换为NOOP。
## 影响版本
未具体指出版本,但该漏洞存在于使用Etron HC控制器的系统中。
## 漏洞细节
在`prepare_transfer()`和`prepare_ring()`函数之前进行的检查,可能导致`enqueue`指针已指向段的最终链接TRB。在某些情况下(约0.4%的调用次数),直接访问`enqueue + 1`会导致无效指针引用,从而导致内核崩溃或将垃圾数据加载为链接TRB,导致真实的链接TRB被替换为NOOP,从而导致系统不稳定或崩溃。
## 影响
该漏洞会导致系统在使用Etron HC控制器及其变通方案时发生崩溃。使用漏洞修复补丁后,控制传输压力测试不再导致系统崩溃。
CVSS信息
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
漏洞类别
空指针解引用
漏洞标题
usb: xhci: Fix invalid pointer dereference in Etron workaround
漏洞描述信息
In the Linux kernel, the following vulnerability has been resolved:
usb: xhci: Fix invalid pointer dereference in Etron workaround
This check is performed before prepare_transfer() and prepare_ring(), so
enqueue can already point at the final link TRB of a segment. And indeed
it will, some 0.4% of times this code is called.
Then enqueue + 1 is an invalid pointer. It will crash the kernel right
away or load some junk which may look like a link TRB and cause the real
link TRB to be replaced with a NOOP. This wouldn't end well.
Use a functionally equivalent test which doesn't dereference the pointer
and always gives correct result.
Something has crashed my machine twice in recent days while playing with
an Etron HC, and a control transfer stress test ran for confirmation has
just crashed it again. The same test passes with this patch applied.
CVSS信息
N/A
漏洞类别
N/A