Bug 2422758 (CVE-2025-68239) - CVE-2025-68239 kernel: binfmt_misc: restore write access before closing files opened by open_exec()
Summary: CVE-2025-68239 kernel: binfmt_misc: restore write access before closing files...
Keywords:
Status: NEW
Alias: CVE-2025-68239
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-12-16 15:02 UTC by OSIDB Bzimport
Modified: 2025-12-19 04:09 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2025-12-16 15:02:35 UTC
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.


Note You need to log in before you can comment on or make changes to this bug.