NFSD: cap the number of listeners accepted in listener_set

State
Published
Severity
Not Scored
Published
Nov 19, 2026
Updated
Nov 19, 2026
Reserved
Sep 25, 2026

Read the record on cve.org

Description

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

NFSD: cap the number of listeners accepted in listener_set

nfsd_nl_listener_set_doit() matches each requested listener against the existing set. The nested loop that does this is O(N * M), where N is the requested count and M is the existing count. The loop runs under sv_lock with bottom halves disabled. A userland request with a very large listener list can therefore spin in atomic context for a long time.

Reject a request that carries more than NFSD_NL_LISTENER_MAX (1024) entries. The check goes in nfsd_nl_validate_listeners(), before the code takes any lock. The limit is far above any realistic configuration.

This patch does not cap M. Only the message size bounded N; real sockets bound M. A listener_set result set is the requested set, so that path also holds M at the cap, but __write_ports_addxprt() adds two listeners per call and removes none, so repeated calls can push M past it. The worst case under sv_lock is therefore 1024 * M, plus 1024 nla_parse_nested() calls. Both interfaces require CAP_NET_ADMIN.

ProductVersions
Linux Linux16a471177496c8e04a9793812c187a2c1a2192fa to before 4a6c685d7e443d5c12197d01576202544247d107 Affected16a471177496c8e04a9793812c187a2c1a2192fa to before f256b39c64e956d9db46c5a42be99f9fe9685919 Affected16a471177496c8e04a9793812c187a2c1a2192fa to before 340fd5acb07f0299e71afc54a4a4b32e129177c4 Affected16a471177496c8e04a9793812c187a2c1a2192fa to before 9a05e5ee0a98b9550521df86936b5f825bc07ec2 Affected
Linux Linux6.10 Affectedbefore 6.10 Not Affected6.12.117 through 6.12.* Not Affected6.18.61 through 6.18.* Not Affected7.3.2 through 7.3.* Not Affected7.4-rc1 and later Not Affected

Weaknesses

The record names no weakness.

References

Every record here comes from the CVE Program's CVE List. © 1999-2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.

© 2026 NVIDIA, the NVIDIA logo, and NVIDIA Inception are trademarks and/or registered trademarks of NVIDIA Corporation in the U.S. and other countries.