{"id":"CVE-2026-89661","revision":"248586840c1e4d9e8d1a49f52a82b764","records":[{"revision":"248586840c1e4d9e8d1a49f52a82b764","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2026-89661","aliases":[],"title":"NFSD: Prevent post-shutdown use-after-free in unlock_filesystem","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nNFSD: Prevent post-shutdown use-after-free in unlock_filesystem\n\nWriting a filesystem path to /proc/fs/nfsd/unlock_filesystem runs\nnfsd4_cancel_copy_by_sb() before nfsd_mutex is held and before the\nhandler confirms that nn->nfsd_serv is set. Once nfsd has shut down,\nnfs4_state_destroy_net() has freed nn->conf_id_hashtbl but left the\npointer intact, so the cancel helper iterates freed slab memory as an\narray of struct list_head and then dereferences a bogus nfs4_client\nwhen it takes clp->async_lock. A local administrator holding\nCAP_SYS_ADMIN can reach this use-after-free by stopping the server and\nthen writing to unlock_filesystem; KASAN reports a slab-use-after-free\nread in nfsd4_cancel_copy_by_sb().\n\nnfsd4_revoke_states() walks the same state tables and for that reason\nalready runs only under nfsd_mutex with nn->nfsd_serv confirmed\npresent. Move the async COPY cancel into that protected section so\nevery NFSv4 state-table walker on this path observes a running server.\nAsync copies exist only while the server runs, so gating the cancel on\nnn->nfsd_serv loses nothing.","state":0,"publishedAt":"2026-09-11T19:45:49.086+00:00","modifiedAt":"2026-10-19T08:50:32.806+00:00","affected":[{"ecosystem":"Vendor product","name":"Linux","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"product\": \"Linux\",\n                    \"vendor\": \"Linux\",\n                    \"defaultStatus\": \"unaffected\",\n                    \"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\n                    \"programFiles\": [\n                        \"fs/nfsd/nfsctl.c\"\n                    ],\n                    \"versions\": [\n                        {\n                            \"version\": \"3daab3112f039cf849f96764019b096bb0a39d04\",\n                            \"lessThan\": \"0c1a755b7212e0835398d4df5e782ea85ccd7476\",\n                            \"status\": \"affected\",\n                            \"versionType\": \"git\"\n                        },\n                        {\n                            \"version\": \"3daab3112f039cf849f96764019b096bb0a39d04\",\n                            \"lessThan\": \"292d915d3ba6fd15eeb88351fa10581683073109\",\n                            \"status\": \"affected\",\n                            \"versionType\": \"git\"\n                        }\n                    ]\n                }"},{"ecosystem":"Vendor product","name":"Linux","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"product\": \"Linux\",\n                    \"vendor\": \"Linux\",\n                    \"defaultStatus\": \"affected\",\n                    \"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\n                    \"programFiles\": [\n                        \"fs/nfsd/nfsctl.c\"\n                    ],\n                    \"versions\": [\n                        {\n                            \"version\": \"7.0\",\n                            \"status\": \"affected\"\n                        },\n                        {\n                            \"version\": \"0\",\n                            \"lessThan\": \"7.0\",\n                            \"status\": \"unaffected\",\n                            \"versionType\": \"semver\"\n                        },\n                        {\n                            \"version\": \"7.2.4\",\n                            \"lessThanOrEqual\": \"7.2.*\",\n                            \"status\": \"unaffected\",\n                            \"versionType\": \"semver\"\n                        },\n                        {\n                            \"version\": \"7.3\",\n                            \"lessThanOrEqual\": \"*\",\n                            \"status\": \"unaffected\",\n                            \"versionType\": \"original_commit_for_fix\"\n                        }\n                    ]\n                }"}],"metrics":[],"references":["https://git.kernel.org/stable/c/0c1a755b7212e0835398d4df5e782ea85ccd7476","https://git.kernel.org/stable/c/292d915d3ba6fd15eeb88351fa10581683073109"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-89661","license":"CVE Program Terms of Use","key":"cve-program:CVE-2026-89661","identifiers":["CVE-2026-89661"]},"retained":false,"historicalAffected":[]}],"coverage":[]}