# CVE-2026-31426: ACPI: EC: clean up handlers on probe failure in acpi\_ec\_setup()

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.0
- **CVSS:** 7.0 (v3.1, CNA) `CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: High; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.16% (percentile 3, 2026-11-26)
- **CWE:** CWE-416
- **Published:** 2026-04-13T13:40:29.635Z
- **Modified:** 2026-10-19T19:17:53.040Z

## Who should check

- Anyone running Linux \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 022d1727f33ff90b3e1775125264e3023901952e; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 9c886e63b69658959633937e3acb7ca8addf7499; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 808c0f156f48d5b8ca34088cbbfba8444e606cbc; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< d04c007047c88158141d9bd5eac761cdadd3782c; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< be1a827e15991e874e0d5222d0ea5fdad01960fe; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< f6484cadbcaf26b5844b51bd7307a663dda48ef6
- Anyone running Linux 5.7

## Description

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

ACPI: EC: clean up handlers on probe failure in acpi\_ec\_setup()

When ec\_install\_handlers() returns -EPROBE\_DEFER on reduced-hardware
platforms, it has already started the EC and installed the address
space handler with the struct acpi\_ec pointer as handler context.
However, acpi\_ec\_setup() propagates the error without any cleanup.

The caller acpi\_ec\_add() then frees the struct acpi\_ec for non-boot
instances, leaving a dangling handler context in ACPICA.

Any subsequent AML evaluation that accesses an EC OpRegion field
dispatches into acpi\_ec\_space\_handler() with the freed pointer,
causing a use-after-free:

 BUG: KASAN: slab-use-after-free in mutex\_lock (kernel/locking/mutex.c:289)
 Write of size 8 at addr ffff88800721de38 by task init/1
 Call Trace:
  \<TASK\>
  mutex\_lock (kernel/locking/mutex.c:289)
  acpi\_ec\_space\_handler (drivers/acpi/ec.c:1362)
  acpi\_ev\_address\_space\_dispatch (drivers/acpi/acpica/evregion.c:293)
  acpi\_ex\_access\_region (drivers/acpi/acpica/exfldio.c:246)
  acpi\_ex\_field\_datum\_io (drivers/acpi/acpica/exfldio.c:509)
  acpi\_ex\_extract\_from\_field (drivers/acpi/acpica/exfldio.c:700)
  acpi\_ex\_read\_data\_from\_field (drivers/acpi/acpica/exfield.c:327)
  acpi\_ex\_resolve\_node\_to\_value (drivers/acpi/acpica/exresolv.c:392)
  \</TASK\>

 Allocated by task 1:
  acpi\_ec\_alloc (drivers/acpi/ec.c:1424)
  acpi\_ec\_add (drivers/acpi/ec.c:1692)

 Freed by task 1:
  kfree (mm/slub.c:6876)
  acpi\_ec\_add (drivers/acpi/ec.c:1751)

The bug triggers on reduced-hardware EC platforms (ec-\>gpe \< 0)
when the GPIO IRQ provider defers probing. Once the stale handler
exists, any unprivileged sysfs read that causes AML to touch an
EC OpRegion (battery, thermal, backlight) exercises the dangling
pointer.

Fix this by calling ec\_remove\_handlers() in the error path of
acpi\_ec\_setup() before clearing first\_ec. ec\_remove\_handlers()
checks each EC\_FLAGS\_\* bit before acting, so it is safe to call
regardless of how far ec\_install\_handlers() progressed:

  -ENODEV  (handler not installed): only calls acpi\_ec\_stop()
  -EPROBE\_DEFER (handler installed): removes handler, stops EC

## Affected and fixed versions

- Linux: \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 022d1727f33ff90b3e1775125264e3023901952e; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 9c886e63b69658959633937e3acb7ca8addf7499; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 808c0f156f48d5b8ca34088cbbfba8444e606cbc; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< d04c007047c88158141d9bd5eac761cdadd3782c; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< be1a827e15991e874e0d5222d0ea5fdad01960fe; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< f6484cadbcaf26b5844b51bd7307a663dda48ef6 (cvelist)
- Linux: 5.7 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-31426. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-31426.md
Affected: Linux >= 03e9a0e05739cf872fee494b06c75c0469704a21, < 022d1727f33ff90b3e1775125264e3023901952e; >= 03e9a0e05739cf872fee494b06c75c0469704a21, < 9c886e63b69658959633937e3acb7ca8addf7499; >= 03e9a0e05739cf872fee494b06c75c0469704a21, < 808c0f156f48d5b8ca34088cbbfba8444e606cbc; >= 03e9a0e05739cf872fee494…
Fixed in: Linux 022d1727f33ff90b3e1775125264e3023901952e, Linux 9c886e63b69658959633937e3acb7ca8addf7499, Linux 808c0f156f48d5b8ca34088cbbfba8444e606cbc

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-31426 being exploited?

There is no confirmed exploitation: CVE-2026-31426 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.16% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-31426?

High: CVSS 7.0 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed). The attack needs conditions outside the attacker's control, which makes it harder.

### Which versions are affected by CVE-2026-31426?

Linux \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 022d1727f33ff90b3e1775125264e3023901952e; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 9c886e63b69658959633937e3acb7ca8addf7499; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< 808c0f156f48d5b8ca34088cbbfba8444e606cbc; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< d04c007047c88158141d9bd5eac761cdadd3782c; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< be1a827e15991e874e0d5222d0ea5fdad01960fe; \>= 03e9a0e05739cf872fee494b06c75c0469704a21, \< f6484cadbcaf26b5844b51bd7307a663dda48ef6; Linux 5.7.

### Is there a fix for CVE-2026-31426?

Yes. Fixed in Linux 022d1727f33ff90b3e1775125264e3023901952e, Linux 9c886e63b69658959633937e3acb7ca8addf7499, Linux 808c0f156f48d5b8ca34088cbbfba8444e606cbc. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2026-31426?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/022d1727f33ff90b3e1775125264e3023901952e>
- patch: <https://git.kernel.org/stable/c/9c886e63b69658959633937e3acb7ca8addf7499>
- patch: <https://git.kernel.org/stable/c/808c0f156f48d5b8ca34088cbbfba8444e606cbc>
- patch: <https://git.kernel.org/stable/c/d04c007047c88158141d9bd5eac761cdadd3782c>
- patch: <https://git.kernel.org/stable/c/be1a827e15991e874e0d5222d0ea5fdad01960fe>
- patch: <https://git.kernel.org/stable/c/f6484cadbcaf26b5844b51bd7307a663dda48ef6>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-31426>

HTML: <https://flawdb.com/CVE-2026-31426> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-31426>
