Linux: Use After Free
CVE-2025-22023 is a high-severity use after free vulnerability in Linux, with a CVSS 3.1 base score of 7.8 out of 10. It can be exploited with local access to the system by an attacker with a low-privileged account, without any action from a user. The record lists versions 6af20ac254cbd0e1178a3542767c9308e209eee5, 49cf6f5293aeb706dd672608478336a003f37df6, de9e78167f760a699806793d7c987239e4f6c8c3 as the first without the flaw, so updating Linux to one of those releases or later removes the exposure. There is no confirmed exploitation so far. EPSS estimates a 0.2% chance of exploitation within 30 days, which is low compared with other CVEs.
High severity with no evidence of exploitation so far.
What to do
- Update Linux to 6af20ac254cbd0e1178a3542767c9308e209eee5 or 49cf6f5293aeb706dd672608478336a003f37df6 or de9e78167f760a699806793d7c987239e4f6c8c3 or 58d0a3fab5f4fdc112c16a4c6d382f62097afd1c, whichever matches your release line, or a later version.
- Update Linux Kernel to 6.12.22 or 6.13.10, whichever matches your release line, or a later version.
Affected products and versions
| Vendor | Product | Affected versions | Fixed in |
|---|---|---|---|
| Linux | Linux | d56b0b2ab142940b06eac56dcb3ab1ab88df38a2 up to, but not including, 6af20ac254cbd0e1178a3542767c9308e209eee5; d56b0b2ab142940b06eac56dcb3ab1ab88df38a2 up to, but not including, 49cf6f5293aeb706dd672608478336a003f37df6; d56b0b2ab142940b06eac56dcb3ab1ab88df38a2 up to, but not including, de9e78167f760a699806793d7c987239e4f6c8c3; d56b0b2ab142940b06eac56dcb3ab1ab88df38a2 up to, but not including, 58d0a3fab5f4fdc112c16a4c6d382f62097afd1c; 6.11 | 6af20ac254cbd0e1178a3542767c9308e209eee5, 49cf6f5293aeb706dd672608478336a003f37df6, de9e78167f760a699806793d7c987239e4f6c8c3, 58d0a3fab5f4fdc112c16a4c6d382f62097afd1c |
| Linux | Linux Kernel | 6.11 up to, but not including, 6.12.22; 6.13 up to, but not including, 6.13.10; 6.14 | 6.12.22, 6.13.10 |
Version data comes from the organisation that assigned the CVE. Confirm against the vendor advisory before deciding you are unaffected.
How the severity score breaks down
- Attack vector
- LocalThe attacker needs local access or must trick a user into running something.
- Attack complexity
- LowNo special conditions are needed; the attack works reliably.
- Privileges required
- LowA basic user account is enough.
- User interaction
- NoneNo action by a victim is required.
- Scope
- UnchangedImpact stays within the vulnerable component.
- Confidentiality
- HighAll data handled by the component can be read.
- Integrity
- HighData or code can be modified at will.
- Availability
- HighThe component can be taken down completely.
Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H. Scored by NVD.
Official description
In the Linux kernel, the following vulnerability has been resolved: usb: xhci: Don't skip on Stopped - Length Invalid Up until commit d56b0b2ab142 ("usb: xhci: ensure skipped isoc TDs are returned when isoc ring is stopped") in v6.11, the driver didn't skip missed isochronous TDs when handling Stoppend and Stopped - Length Invalid events. Instead, it erroneously cleared the skip flag, which would cause the ring to get stuck, as future events won't match the missed TD which is never removed from the queue until it's cancelled. This buggy logic seems to have been in place substantially unchanged since the 3.x series over 10 years ago, which probably speaks first and foremost about relative rarity of this case in normal usage, but by the spec I see no reason why it shouldn't be possible. After d56b0b2ab142, TDs are immediately skipped when handling those Stopped events. This poses a potential problem in case of Stopped - Length Invalid, which occurs either on completed TDs (likely already given back) or Link and No-Op TRBs. Such event won't be recognized as matching any TD (unless it's the rare Link TRB inside a TD) and will result in skipping all pending TDs, giving them back possibly before they are done, risking isoc data loss and maybe UAF by HW. As a compromise, don't skip and don't clear the skip flag on this kind of event. Then the next event will skip missed TDs. A downside of not handling Stopped - Length Invalid on a Link inside a TD is that if the TD is cancelled, its actual length will not be updated to account for TRBs (silently) completed before the TD was stopped. I had no luck producing this sequence of completion events so there is no compelling demonstration of any resulting disaster. It may be a very rare, obscure condition. The sole motivation for this patch is that if such unlikely event does occur, I'd rather risk reporting a cancelled partially done isoc frame as empty than gamble with UAF. This will be fixed more properly by looking at Stopped event's TRB pointer when making skipping decisions, but such rework is unlikely to be backported to v6.12, which will stay around for a few years.
Source: the CVE record as published by its numbering authority, via NVD and CVE.org.
The underlying weakness: Use After Free
The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. Any operations using the original pointer are no longer valid because the memory belongs to the code that operates on the new pointer.
How developers prevent this class of flaw
- Choose a language that provides automatic memory management.
- When freeing pointers, be sure to set them to NULL once they are freed. However, the utilization of multiple or complex data structures may lower the usefulness of this strategy.
Timeline
- CVE record published.
- Record last changed materially (score, affected products, status or references).
References
Patches and release notes
Recent Use After Free vulnerabilities
- 8.8 High severity
- 7.8 High severity
- 7.8 High severity
- 9.8 Critical severity
- 7.8 High severity
- 7.8 High severity
Spotted an error? Tell us.