CVE-2026-89662 PUBLISHED

NFSD: Prevent lock owner use-after-free during client teardown

Assigner: Linux
Reserved: 11.09.2026 Published: 11.09.2026 Updated: 13.09.2026

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

NFSD: Prevent lock owner use-after-free during client teardown

__destroy_client() releases a client's open owners, but a lock owner whose only reference is a blocked lock (nbl) stays on cl_ownerstr_hashtbl. client_has_state() does not count a bare owner, so DESTROY_CLIENTID can reach __destroy_client() with such owners present.

__destroy_client() then walks the table, calling remove_blocked_locks() on each owner without a reference. Freeing a blocked lock drops the owner reference held via flc_owner. The per-net laundromat reaps blocked locks from nn->blocked_locks_lru independently of client state. The two paths share blocked_locks_lock only for the list splice, not the owner's lifetime. The laundromat therefore frees the owner as __destroy_client() dereferences it, a NULL dereference in remove_blocked_locks().

nfsd4_release_lockowner() holds a reference across the same call; __destroy_client() does not. Hold cl_lock across the walk, taking a reference and unhashing each owner, then drop it before remove_blocked_locks() and nfs4_put_stateowner(), which take blocked_locks_lock and cl_lock.

Metrics

CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS Score: 9.8

AV:N - The bug is in nfsd NFSv4.1 client teardown and blocked-lock handling, reached by remote COMPOUND RPCs on the in-kernel NFS server (TCP/UDP 2049). A network client drives EXCHANGE_ID, CREATE_SESSION, OPEN, blocking LOCK, DESTROY_SESSION, and DESTROY_CLIENTID into __destroy_client(). AC:L - The attacker controls both sides of the race: one client holds a conflicting lock while another queues a blocked lock, then DESTROY_CLIENTID races with lock-grant/CB_NOTIFY_LOCK or the laundromat freeing that lockowner. Concurrent NFS requests create the race, and it can be retried. PR:N - Typical nfsd deployments use AUTH_SYS, which does not cryptographically authenticate the client. A remote peer that can reach an export can create NFSv4.1 state and issue DESTROY_CLIENTID without a local account or kernel capabilities on the server. UI:N - Exploitation requires only attacker-sent NFS RPCs against a running nfsd export. No victim user action such as mounting a filesystem or opening a local file on the server is required. S:U - The use-after-free occurs in kernel nfsd lock-owner state on the NFS server host and does not cross a separate security authority such as a VM, guest/host, or IOMMU boundary. C:H - This is a use-after-free of the nfs4_lockowner slab object. Reclaiming the freed owner lets an attacker control later reads of so_client and related pointers in remove_blocked_locks(), yielding a kernel information-disclosure primitive. I:H - The same UAF is exploitable for integrity: the freed lockowner includes so_ops function pointers and lo_blocked list heads, so heap reuse can hijack control flow or corrupt list pointers for an arbitrary kernel write. A:H - The bug is a kernel use-after-free of the lock owner and was observed as a NULL dereference in remove_blocked_locks(), which can oops or panic nfsd and take down the server.

Product Status

Vendor Linux
Product Linux
Versions Default: unaffected
  • affected from 68ef3bc3166468678d5e1fdd216628c35bd1186f to a6ead6fff3a7d03e49845f048f7000a2e0d34431 (excl.)
  • affected from 68ef3bc3166468678d5e1fdd216628c35bd1186f to 4804c58f73a80d12df1de323bf97a164f6ee8743 (excl.)
  • affected from 68ef3bc3166468678d5e1fdd216628c35bd1186f to 8cf4ff0a7c083dd5e0067f517d63979b74b66649 (excl.)
  • affected from 68ef3bc3166468678d5e1fdd216628c35bd1186f to 5e2fa29d223a9a1e6a948e40b109d09081d1decd (excl.)
  • Version e294c4c2d33b7307a89cdf31bec08a112d6a9297 is affected
  • Version 797bfd05d4040fbf766198b3cfcc1838002cc890 is affected
  • Version 0f44e9da465ea259b6c9f31a627f3c50a16e1679 is affected
  • affected from 4.9.91 to 4.10 (excl.)
  • affected from 4.14.31 to 4.15 (excl.)
  • affected from 4.15.14 to 4.16 (excl.)
Vendor Linux
Product Linux
Versions Default: affected
  • Version 4.16 is affected
  • unaffected from 0 to 4.16 (excl.)
  • unaffected from 6.12.109 to 6.12.* (incl.)
  • unaffected from 6.18.50 to 6.18.* (incl.)
  • unaffected from 7.2.4 to 7.2.* (incl.)
  • unaffected from 7.3-rc1 to * (incl.)

References