CVE-2026-63978
Received Received - Intake

Memory Leak in Linux Kernel Network Handshake

Vulnerability report for CVE-2026-63978, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-07-19

Last updated on: 2026-07-19

Assigner: kernel.org

Description

In the Linux kernel, the following vulnerability has been resolved: net/handshake: Drain pending requests at net namespace exit The arguments to list_splice_init() in handshake_net_exit() are reversed. The call moves the local empty "requests" list onto hn->hn_requests, leaving the local list empty, so the subsequent drain loop runs zero iterations. Pending handshake requests that had not yet been accepted are not torn down when the net namespace is destroyed; each one keeps a reference on a socket file and on the handshake_req allocation. Pass the source and destination in the documented order (list_splice_init(list, head) moves list onto head) so the pending list is transferred to the local scratch list and drained through handshake_complete(). Fixing the splice direction exposes a list-corruption race. After the splice each req->hr_list still has non-empty link pointers, threading the stack-local scratch list rather than hn_requests. A concurrent handshake_req_cancel() -- for example, from sunrpc's TLS timeout on a kernel socket whose netns reference was not taken -- finds the request through the rhashtable, calls remove_pending(), and sees !list_empty(&req->hr_list). __remove_pending_locked() then list_del_init()s an entry off the scratch list while the drain iterates, corrupting it. The same call arriving after the drain loop has run list_del() on an entry hits LIST_POISON instead. Have remove_pending() check HANDSHAKE_F_NET_DRAINING under hn_lock and report not-found when drain is in progress. The drain has already taken ownership; handshake_complete()'s existing test_and_set on HANDSHAKE_F_REQ_COMPLETED still arbitrates between drain and cancel for who calls the consumer's hp_done. Use list_del_init() rather than list_del() in the drain so req->hr_list does not carry LIST_POISON after drain releases the entry. The DRAINING guard in remove_pending() makes cancel return false, but cancel still falls through to test_and_set_bit on HANDSHAKE_F_REQ_COMPLETED and drops the request's hr_file reference. Without another pin, if that is the last reference, sk_destruct frees the request while it is still linked on the drain loop's local list. Pin each request's hr_file under hn_lock before releasing the list, and drop that drain pin after the loop finishes with the request.

CVSS Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-07-19
Last Modified
2026-07-19
Generated
2026-07-20
AI Q&A
2026-07-19
EPSS Evaluated
N/A
NVD
EUVD

Affected Vendors & Products

Showing 1 associated CPE
Vendor Product Version / Range
linux linux_kernel *

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-UNKNOWN

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

This vulnerability in the Linux kernel involves a reversed argument in the list_splice_init() function within handshake_net_exit(). This causes pending handshake requests to not be properly torn down when a network namespace is destroyed, leaving references to sockets and memory allocations. A subsequent race condition can corrupt lists when concurrent operations attempt to cancel requests during the drain process.

Detection Guidance

This vulnerability is specific to the Linux kernel's network handshake mechanism and may not have direct detection commands. Monitor for unusual socket references or pending handshake requests not being cleaned up during net namespace destruction. Check kernel logs for handshake-related errors or corruption messages.

Impact Analysis

This flaw could lead to resource leaks where sockets and memory are not freed after use, potentially causing system instability or denial of service. It may also allow unauthorized access to network resources if pending requests remain active after namespace destruction.

Compliance Impact

This vulnerability does not directly affect compliance with standards like GDPR or HIPAA. It involves a kernel-level network namespace issue that could lead to resource leaks but does not explicitly impact data protection or privacy requirements central to these regulations.

Mitigation Strategies

Apply the kernel patch that fixes the reversed arguments in list_splice_init() and the subsequent race conditions. Update to a patched kernel version where this issue is resolved. Monitor for any signs of list corruption or failed handshake requests.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-63978. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart