CVE-2025-71074
Last modified
CVE-2025-71074 is a medium-severity vulnerability rated 4.7/10 on the CVSS scale. In the Linux kernel, the following vulnerability has been resolved: functionfs: fix the open/removal races ffs_epfile_open() can race with removal, ending up with file->private_data pointing to freed object. There is a total count of opened files on functionfs (both ep0 and dynamic ones) and when it hits zero, dynamic files get removed. Unfortunately, that removal can happen while another thread is in ffs_epfile_open(), but has not incremented the count yet. In that case open will succeed, leaving us with UAF on any subsequent read() or write(). The root cause is that ffs->opened is misused; atomic_dec_and_test() vs. atomic_add_return() is not a good idea, when object remains visible all along. To untangle that * serialize openers on ffs->mutex (both for ep0 and for dynamic files) * have dynamic ones use atomic_inc_not_zero() and fail if we had zero ->opened; in that case the file we are opening is doomed. * have the inodes of dynamic files marked on removal (from the callback of simple_recursive_removal()) - clear ->i_private there. * have open of dynamic ones verify they hadn't been already removed, along with checking that state is FFS_ACTIVE.. EPSS estimates a 0.09% chance of exploitation in the next 30 days.
Description
In the Linux kernel, the following vulnerability has been resolved: functionfs: fix the open/removal races ffs_epfile_open() can race with removal, ending up with file->private_data pointing to freed object. There is a total count of opened files on functionfs (both ep0 and dynamic ones) and when it hits zero, dynamic files get removed. Unfortunately, that removal can happen while another thread is in ffs_epfile_open(), but has not incremented the count yet. In that case open will succeed, leaving us with UAF on any subsequent read() or write(). The root cause is that ffs->opened is misused; atomic_dec_and_test() vs. atomic_add_return() is not a good idea, when object remains visible all along. To untangle that * serialize openers on ffs->mutex (both for ep0 and for dynamic files) * have dynamic ones use atomic_inc_not_zero() and fail if we had zero ->opened; in that case the file we are opening is doomed. * have the inodes of dynamic files marked on removal (from the callback of simple_recursive_removal()) - clear ->i_private there. * have open of dynamic ones verify they hadn't been already removed, along with checking that state is FFS_ACTIVE.
Metrics
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H
Weakness Enumeration
Affected Software
| Vendor | Product | Versions | Update |
|---|---|---|---|
| Linux | Linux Kernel | >= 2.6.35.1, < 6.19 | — |
| Linux | Linux Kernel | 2.6.35 | — |
| Linux | Linux Kernel | 6.19 | Rc1 |
References
Timeline
- Published
- Last Modified
- Status
- Modified
Frequently Asked Questions
What is CVE-2025-71074?
How severe is CVE-2025-71074?
How do I fix CVE-2025-71074?
How Strix Helps
- How Strix found a critical auth bypass in etcdStrix autonomously discovered a critical authentication bypass in etcd, later designated CVE-2026-33413.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2025
- CVE-2025-71069In the Linux kernel, the following vulnerability has been re…
- CVE-2025-7107A vulnerability classified as critical has been found in Sim…7.5
- CVE-2025-71070In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2025-71071In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2025-71072In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2025-71073In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2025-71075In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2025-71076In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2025-71077In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2025-71078In the Linux kernel, the following vulnerability has been re…7.8
- CVE-2025-71079In the Linux kernel, the following vulnerability has been re…5.5
- CVE-2025-7108A vulnerability classified as critical was found in risesoft…5.4
Are you affected by CVE-2025-71074?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
