# CVE-2025-38567: nfsd: avoid ref leak in nfsd_open_local_fh()

- Severity: Medium 4.7 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.13%, higher than 3% of CVEs (2026-12-01)
- Published: 2025-08-19T17:02:48.306Z
- Modified: 2026-06-17T09:17:07.553Z
- Weaknesses: CWE-362
- Assigned by: Linux

## Description

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

nfsd: avoid ref leak in nfsd_open_local_fh()

If two calls to nfsd_open_local_fh() race and both successfully call
nfsd_file_acquire_local(), they will both get an extra reference to the
net to accompany the file reference stored in *pnf.

One of them will fail to store (using xchg()) the file reference in
*pnf and will drop that reference but WON'T drop the accompanying
reference to the net.  This leak means that when the nfs server is shut
down it will hang in nfsd_shutdown_net() waiting for
&nn->nfsd_net_free_done.

This patch adds the missing nfsd_net_put().

(As written by CVE List.)

## Affected

- Linux Linux: from 986a21ace186433e0397a59491646edad8c8d636 before fcb0a417fddb605530c4837e0996620f8ed38023; from e6f7e1487ab528a6c653bd0d42812ff2942846cd before c4bf8f26c51e51bbb840935659a7b3b65a802c07; from e6f7e1487ab528a6c653bd0d42812ff2942846cd before e5a73150776f18547ee685c9f6bfafe549714899; from 6.15.3 before 6.15.10; 6.16 (not affected: before 6.16; from 6.15.10 up to 6.15.*; from 6.16.1 up to 6.16.*; from 6.17 up to *)
- linux linux_kernel: from 6.15.3 before 6.15.10; 6.16; 6.17

## References

- <https://git.kernel.org/stable/c/fcb0a417fddb605530c4837e0996620f8ed38023> (patch)
- <https://git.kernel.org/stable/c/c4bf8f26c51e51bbb840935659a7b3b65a802c07> (patch)
- <https://git.kernel.org/stable/c/e5a73150776f18547ee685c9f6bfafe549714899> (patch)

## Sources

- CVE List: [CVE-2025-38567](https://www.cve.org/CVERecord?id=CVE-2025-38567), CVE Terms of Use, modified 2026-05-23
- NVD: [CVE-2025-38567](https://nvd.nist.gov/vuln/detail/CVE-2025-38567), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2025-38567 · Whole record: https://cve.day/CVE-2025-38567.json · Rebuilt by cve.day 2026-11-25T22:59:02.710Z
