CVE-2021-47586

net: stmmac: dwmac-rk: fix oob read in rk_gmac_setup

MEDIUM
5.5
CVSS Score
Published: June 19, 2024 at 02:53 PM UTC
Updated: June 17, 2026 at 04:17 AM UTC
1 product affected across 1 vendorLinux Kernel

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.5
Exploit prediction
EPSS 0.2%
SSVC
No known exploit

Description

In the Linux kernel, the following vulnerability has been resolved: net: stmmac: dwmac-rk: fix oob read in rk_gmac_setup KASAN reports an out-of-bounds read in rk_gmac_setup on the line: while (ops->regs[i]) { This happens for most platforms since the regs flexible array member is empty, so the memory after the ops structure is being read here. It seems that mostly this happens to contain zero anyway, so we get lucky and everything still works. To avoid adding redundant data to nearly all the ops structures, add a new flag to indicate whether the regs field is valid and avoid this loop when it is not.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

5.14 ≤ v < 5.15.115.14 ≤ v < 5.163bb3d6b1c1957e88bfc5e77a4557f7e6ba761fe35.16 rc15.16 rc25.16 rc35.16 rc45.16 rc5
Vendor states this is fixed in 0546b224cc7717cc8a2db076b0bb069a9c430794 (fixed)
Vendor states this is fixed in 0b4a5d1e15ce72f69be48f38dc0401dab890ae0f (fixed)
Vendor states this is fixed in 5.14 (unaffected)
Vendor states this is fixed in 5.15.11 (unaffected)
Vendor states this is fixed in 5.16 (unaffected)

Remediation

No guide yet

No remediation guidance has been written for this CVE yet. What the record does show:

References (2)

Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/0546b224cc7717cc8a2db076b0bb069a9c430794
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/0b4a5d1e15ce72f69be48f38dc0401dab890ae0f

SSVC — Action Prioritization

SSVCNo known exploitNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

5.5MEDIUMCISA-ADP
Attack Vector
LOCAL
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusANALYZED
CWE
CWE-125

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card