CVE-2021-47159CWE-835

CVE-2021-47159

High · published March 25, 2024

CVSS v3.1
7.8
EPSS
0%
Percentile
15.1
In the wild
Unconfirmed
What it is

In the Linux kernel, the following vulnerability has been resolved:

net: dsa: fix a crash if ->get_sset_count() fails

If ds->ops->get_sset_count() fails then it "count" is a negative error

code such as -EOPNOTSUPP. Because "i" is an unsigned int, the negative

error code is type promoted to a very high value and the loop will

corrupt memory until the system crashes.

Fix this by checking for error codes and changing the type of "i" to

just int.

The record
Technical detail
CVSS v3.1
7.8 · HIGH
Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
CVSS v4.0
Not supplied
EPSS
0.00247 · 15.1th percentile
Weakness
CWE-835 · Loop with Unreachable Exit Condition ('Infinite Loop')
Published
2024-03-25T14:15Z
Affected products (7)
ProductVersionsFixed in
linux/linux_kernel≥ 4.7, < 4.19.1934.19.193
linux/linux_kernel≥ 4.20, < 5.4.1245.4.124
linux/linux_kernel≥ 5.5, < 5.10.425.10.42
linux/linux_kernel≥ 5.11, < 5.12.95.12.9
linux/linux_kernelall versions—
linux/linux_kernelall versions—
linux/linux_kernelall versions—
References (10)
EPSS history
Timeline
  • 25 MAR 09:16Z
    net: dsa: fix a crash if ->get_sset_count() fails
    cvelistv5