In the Linux kernel, the following vulnerability has been resolved: usb: gadget: f_ecm: Refactor bind path to use __free() After an bind/unbind… (CVE-2025-40093)
A vulnerability in the Linux kernel's USB gadget function (f_ecm) involves improper cleanup after a bind/unbind cycle, leading to a NULL pointer dereference. This occurs because a stale notify request is freed incorrectly if a subsequent bind fails. The issue has been addressed by refactoring the error handling to use an automatic cleanup mechanism.
AI Analysis
Technical Summary
CVE-2025-40093 describes a flaw in the Linux kernel's USB gadget Ethernet Control Model (f_ecm) driver. After a bind/unbind cycle, the ecm->notify_req pointer remains stale. If a subsequent bind operation fails, the error handling code attempts to free this stale request, causing a NULL pointer dereference when accessing ep->ops->free_request. The fix refactors the bind path to use the __free() automatic cleanup mechanism, preventing the stale pointer dereference.
Potential Impact
This vulnerability can cause a NULL pointer dereference leading to a kernel crash (denial of service) and potentially allows an attacker with local privileges to escalate impact to confidentiality, integrity, and availability of the system. The CVSS v3.1 vector indicates local attack vector, low complexity, low privileges required, no user interaction, unchanged scope, and high impact on confidentiality, integrity, and availability.
Mitigation Recommendations
A fix has been implemented in the Linux kernel by refactoring the bind path to use the __free() automatic cleanup mechanism. Users should apply the official kernel updates that include this fix. Since no patch links are provided here, check the Linux kernel vendor advisories or mainline kernel repositories for the updated versions containing this fix. No alternative mitigations are indicated.
In the Linux kernel, the following vulnerability has been resolved: usb: gadget: f_ecm: Refactor bind path to use __free() After an bind/unbind… (CVE-2025-40093)
Description
A vulnerability in the Linux kernel's USB gadget function (f_ecm) involves improper cleanup after a bind/unbind cycle, leading to a NULL pointer dereference. This occurs because a stale notify request is freed incorrectly if a subsequent bind fails. The issue has been addressed by refactoring the error handling to use an automatic cleanup mechanism.
CVSS v3.1
Score 7.8high
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2025-40093 describes a flaw in the Linux kernel's USB gadget Ethernet Control Model (f_ecm) driver. After a bind/unbind cycle, the ecm->notify_req pointer remains stale. If a subsequent bind operation fails, the error handling code attempts to free this stale request, causing a NULL pointer dereference when accessing ep->ops->free_request. The fix refactors the bind path to use the __free() automatic cleanup mechanism, preventing the stale pointer dereference.
Potential Impact
This vulnerability can cause a NULL pointer dereference leading to a kernel crash (denial of service) and potentially allows an attacker with local privileges to escalate impact to confidentiality, integrity, and availability of the system. The CVSS v3.1 vector indicates local attack vector, low complexity, low privileges required, no user interaction, unchanged scope, and high impact on confidentiality, integrity, and availability.
Mitigation Recommendations
A fix has been implemented in the Linux kernel by refactoring the bind path to use the __free() automatic cleanup mechanism. Users should apply the official kernel updates that include this fix. Since no patch links are provided here, check the Linux kernel vendor advisories or mainline kernel repositories for the updated versions containing this fix. No alternative mitigations are indicated.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-7jm9-29fh-9vrx
- Osv Schema Version
- 1.4.0
- Aliases
- ["CVE-2025-40093"]
- Database Specific Severity
- HIGH
- Cvss Version
- 3.1
Threat ID: 6a6b72d69c2644c7f847aee3
Added to database: 07/30/2026, 15:50:46 UTC
Last enriched: 07/30/2026, 16:24:44 UTC
Last updated: 09/10/2026, 19:26:53 UTC
Views: 10
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.