CVE-2026-90077: net: fix a resource leak in copy_net_ns() error handling path

Published Sep 17, 2026
·
Updated

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

net: fix a resource leak in copynetns() error handling path

Currently, preinitnet() does two things:

(1) call nscommoninit() which might fail (2) initialize resources which does not fail

However, preinitnet() is returning early when (1) fails, and copynetns() is jumping to the decucounts: label. As a result, resources allocated by netalloc() are leaking. We need to call keyremovedomain() and netpassivedec() in order to release resources allocated by netalloc().

We cannot simply jump to the putuserns: label when preinitnet() failed, for (2) is not yet done. But we can reorder (1) and (2), for there is no dependency between (1) and (2). Therefore, this patch decouples (1) from preinitnet() and changes preinitnet() back to a void function, and calls nscommoninit() after preinitnet() succeeded. Then, we can jump to immediately after nscommonfree() of the putuserns: label.

Affected Software

1 affected component
Linux Linux kernel

Event History

Sep 17, 2026
CVE Published
via MITRE·04:05 PM
Data Sourced
via MITRE·04:05 PM
Description

Frequently Asked Questions

1

What condition triggers the leak?

The leak occurs when copy_net_ns() allocates network-namespace resources through net_alloc() and ns_common_init() then fails. The existing error path decrements ucounts without releasing the resources allocated by net_alloc().

2

Are successful network namespace creation paths implicated?

The described issue is limited to the error-handling path following a failure of ns_common_init(). The provided information does not indicate a leak when that initialization succeeds.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203