{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2025-71074","id":"CVE-2025-71074","title":"functionfs: fix the open/removal races","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nfunctionfs: fix the open/removal races\n\nffs_epfile_open() can race with removal, ending up with file->private_data\npointing to freed object.\n\nThere is a total count of opened files on functionfs (both ep0 and\ndynamic ones) and when it hits zero, dynamic files get removed.\nUnfortunately, that removal can happen while another threa","descriptionLong":"In the Linux kernel, the following vulnerability has been resolved:\n\nfunctionfs: fix the open/removal races\n\nffs_epfile_open() can race with removal, ending up with file->private_data\npointing to freed object.\n\nThere is a total count of opened files on functionfs (both ep0 and\ndynamic ones) and when it hits zero, dynamic files get removed.\nUnfortunately, that removal can happen while another thread is\nin ffs_epfile_open(), but has not incremented the count yet.\nIn that case open will succeed, leaving us with UAF on any subsequent\nread() or write().\n\nThe root cause is that ffs->opened is misused; atomic_dec_and_test() vs.\natomic_add_return() is not a good idea, when object remains visible all\nalong.\n\nTo untangle that\n\t* serialize openers on ffs->mutex (both for ep0 and for dynamic files)\n\t* have dynamic ones use atomic_inc_not_zero() and fail if we had\nzero ->opened; in that case the file we are opening is doomed.\n\t* have the inodes of dynamic files marked on removal (from the\ncallback of simple_recursive_removal()) - clear ->i_private there.\n\t* have open of dynamic ones verify they hadn't been already removed,\nalong with checking that state is FFS_ACTIVE.","published":"2026-01-13T15:31:27.413Z","updated":"2026-11-01T02:31:06.428750927Z","reserved":"2026-01-13T15:30:19.647Z","status":"Modified","rejected":false,"assigner":"Linux","metric":{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"Linux"},"metrics":[{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"Linux"},{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"416baaa9-dc9f-4396-8d5f-8c081fb06d67"},{"version":"3.1","score":4.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"NVD"},{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"OSV"}],"rating":"high","products":["Linux"],"affectedProducts":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","lessThan":"e002b3c1e6a0faa53329ef0d21e6351bcece6edb","status":"affected","versionType":"git"},{"version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","lessThan":"585a656283c954337036422afcd9cb70dd4135e7","status":"affected","versionType":"git"},{"version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","lessThan":"75240e5e51c6e6d67a3039384125fa54259a3926","status":"affected","versionType":"git"},{"version":"ddf8abd2599491cbad959c700b90ba72a5dce8d0","lessThan":"e5bf5ee266633cb18fff6f98f0b7d59a62819eee","status":"affected","versionType":"git"}],"platforms":[]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"2.6.35","status":"affected"},{"version":"0","lessThan":"2.6.35","status":"unaffected","versionType":"semver"},{"version":"6.1.191","lessThanOrEqual":"6.1.*","status":"unaffected","versionType":"semver"},{"version":"6.6.160","lessThanOrEqual":"6.6.*","status":"unaffected","versionType":"semver"},{"version":"6.12.114","lessThanOrEqual":"6.12.*","status":"unaffected","versionType":"semver"},{"version":"6.19","lessThanOrEqual":"*","status":"unaffected","versionType":"original_commit_for_fix"}],"platforms":[]}],"packages":[],"cwes":["CWE-362"],"aliases":[],"references":[{"url":"https://git.kernel.org/stable/c/e002b3c1e6a0faa53329ef0d21e6351bcece6edb","tags":["web"]},{"url":"https://git.kernel.org/stable/c/585a656283c954337036422afcd9cb70dd4135e7","tags":["web"]},{"url":"https://git.kernel.org/stable/c/75240e5e51c6e6d67a3039384125fa54259a3926","tags":["web"]},{"url":"https://git.kernel.org/stable/c/e5bf5ee266633cb18fff6f98f0b7d59a62819eee","tags":["Patch","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/71xxx/CVE-2025-71074.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-71074","tags":["advisory"]},{"url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","tags":["package"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":null,"epss":0.00132,"epssPercentile":0.02839,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2025-71074","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-71074","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2025-71074","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2025-71074","ok":true,"note":"scored 2026-11-18"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}