# CVE-2025-68239: binfmt\_misc: restore write access before closing files opened by open\_exec()

- Priority: **Routine**
- Reason: Not severe (CVSS 6.8, local access); no exploitation reported by the 5 checked sources
- Next step: Fix in the normal cadence
- Status: published
- Published: 2025-12-16 · Modified: 2026-10-15
- Aliases: UBUNTU-CVE-2025-68239, DEBIAN-CVE-2025-68239
- Record: https://cvemate.com/vulnerability/CVE-2025-68239 · JSON: https://cvemate.com/vulnerability/CVE-2025-68239/json

## Description

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

binfmt_misc: restore write access before closing files opened by open_exec()

bm_register_write() opens an executable file using open_exec(), which
internally calls do_open_execat() and denies write access on the file to
avoid modification while it is being executed.

However, when an error occurs, bm_register_write() closes the file using
filp_close() directly. This does not restore the write permission, which
may cause subsequent write operations on the same file to fail.

Fix this by calling exe_file_allow_write_access() before filp_close() to
restore the write permission properly.
```

## Signals

- CVSS: 6.8 medium (v4.0, OSV · Ubuntu) CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
- EPSS: 0.211%, percentile 11.923%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected (first 20 of 156)

- debian linux (Debian): \< 6.1.170-1 \| \< 6.12.85-1 \| \< 6.17.9-1
- ubuntu linux (Ubuntu): All versions (No fix recorded) \| \< 5.15.0-186.196 \| \< 6.8.0-136.136 \| \< 6.17.0-14.14
- ubuntu linux-allwinner-5.19 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws (Ubuntu): All versions (No fix recorded) \| \< 5.15.0-1112.119 \| \< 6.8.0-1061.64 \| \< 6.17.0-1007.7
- ubuntu linux-aws-5.0 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.11 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.13 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.15 (Ubuntu): \< 5.15.0-1112.119~20.04.1
- ubuntu linux-aws-5.19 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.3 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.4 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.8 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-6.14 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-6.17 (Ubuntu): \< 6.17.0-1007.7~24.04.1
- ubuntu linux-aws-6.2 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-6.5 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-6.8 (Ubuntu): \< 6.8.0-1061.64~22.04.1
- ubuntu linux-aws-fips (Ubuntu): All versions (No fix recorded) \| \< 5.15.0-1112.119+fips1 \| \< 6.8.0-1061.64+fips1
- ubuntu linux-aws-hwe (Ubuntu): All versions (No fix recorded)
- ubuntu linux-azure (Ubuntu): All versions (No fix recorded) \| \< 5.15.0-1117.126 \| \< 6.8.0-1063.71 \| \< 6.17.0-1008.8

## References (first 20 of 44)

- <https://git.kernel.org/stable/c/54274ff90488b6c0f595a6518faed3cf0bc966eb>
- <https://git.kernel.org/stable/c/480ac88431703f2adbb8e6b5bd73c3f3cf9f3d7f>
- <https://git.kernel.org/stable/c/fbab8c08e1a6dbaef81e22d672a7647553101d16>
- <https://git.kernel.org/stable/c/6cce7bc7fac8471c832696720d9c8f2a976d9c54>
- <https://git.kernel.org/stable/c/e785f552ab04dbca01d31f0334f4561240b04459>
- <https://git.kernel.org/stable/c/90f601b497d76f40fa66795c3ecf625b6aced9fd>
- <https://ubuntu.com/security/CVE-2025-68239>
- <https://www.cve.org/CVERecord?id=CVE-2025-68239>
- <https://git.kernel.org/linus/90f601b497d76f40fa66795c3ecf625b6aced9fd>
- <https://ubuntu.com/security/notices/USN-8029-1>
- <https://ubuntu.com/security/notices/USN-8030-1>
- <https://ubuntu.com/security/notices/USN-8029-2>
- <https://ubuntu.com/security/notices/USN-8048-1>
- <https://ubuntu.com/security/notices/USN-8029-3>
- <https://ubuntu.com/security/notices/USN-8567-1>
- <https://ubuntu.com/security/notices/USN-8574-1>
- <https://ubuntu.com/security/notices/USN-8575-1>
- <https://ubuntu.com/security/notices/USN-8576-1>
- <https://ubuntu.com/security/notices/USN-8574-2>
- <https://ubuntu.com/security/notices/USN-8595-1>

---

Data as of 2026-12-05T03:32:23.077Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
