can: ucan: Fix infinite loop from zero-length messages
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 9f2d3eae88d26c29d96e42983b755940d9169cd9 · < aa9e0a7fe5efc2f74327fd37d828e9a51d9ff588| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
can: ucan: Fix infinite loop from zero-length messages
If a broken ucan device gets a message with the message length field set to 0, then the driver will loop for forever in ucan_read_bulk_callback(), hanging the system. If the length is 0, just skip the message and go on to the next one.
This has been fixed in the kvaser_usb driver in the past in commit 0c73772cd2b8 ("can: kvaser_usb: leaf: Fix potential infinite loop in command parsers"), so there must be some broken devices out there like this somewhere.
From the CVE record · Linux
The Linux kernel ucan driver can loop indefinitely when a broken ucan device sends a message whose length field is zero. This can hang the system; the input does not establish whether an attacker can trigger it or whether authentication or user interaction is required.
Engineers running Linux systems with ucan devices should check their kernels; affected versions are not specified.