Skip to main content

Linux Kernel ksmbd EUVDEUVD-2026-24833

| CVE-2026-31477 HIGH
NULL Pointer Dereference (CWE-476)
2026-04-22 416baaa9-dc9f-4396-8d5f-8c081fb06d67 GHSA-crxr-hqjj-5w24
7.5
CVSS 3.1 · Vendor: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Scan for ksmbd on TCP 445
  2. Delivery
    Establish SMB2 session
  3. Exploit
    Send crafted LOCK request
  4. Execution
    Trigger vfs_lock_file error path
  5. Persist
    Induce memory leak or NULL deref
  6. Impact
    System crash (DoS)

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A10:2025 - Mishandling of Exceptional Conditions
ASVS 5.0
V16 - Security Logging and Error Handling Null pointer safety, defensive checks
MITRE ATT&CK

1 technique across 1 tactic: Impact

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires ksmbd kernel module loaded and SMB server listening on network-accessible interface (default TCP port 445). Ksmbd is NOT enabled by default in most Linux distributions-administrators must explicitly configure and start the service, typically for NAS appliances, embedded systems, or container-based file sharing. Exploitation succeeds against default ksmbd configurations with no special protocol features required. Attack is network-based (AV:N), requires no authentication (PR:N), and has low complexity (AC:L) with no user interaction (UI:N). However, practical exploitation is limited to environments where ksmbd is intentionally deployed-standard Linux servers using user-space Samba are immune. The vulnerability surfaces in three distinct code paths (non-UNLOCK errors, UNLOCK ENOENT handling, rollback allocation failure), giving attackers multiple trigger mechanisms.

Impact

CVSS 7.5 (High) with vector AV:N/AC:L/PR:N/UI:N indicates remote unauthenticated exploitation against default ksmbd deployments with low attack complexity and high availability impact. However, multiple risk signals suggest moderate real-world urgency. EPSS probability of 0.02% (7th percentile) indicates minimal attacker interest or scanning activity in the wild-significantly lower than typical network-accessible DoS vulnerabilities. No CISA KEV listing confirms absence of confirmed active exploitation. The severity stems primarily from the network attack surface and kernel-level impact, but practical risk is constrained by ksmbd's limited deployment: it's primarily used in embedded NAS devices, container environments, and specialized file-sharing appliances rather than general-purpose servers where Samba dominates. Attack complexity is low (AC:L) because exploitation requires only sending malformed SMB2_LOCK requests to trigger the error paths, but the DoS nature (A:H, C:N, I:N) limits impact to availability disruption rather than data compromise. Patches available across six stable kernel series (5.15 through 6.19) since early 2026 reduce residual risk for maintained systems. Priority assessment: Medium-High for organizations running ksmbd in production (patch within 30 days), Low-Medium for general Linux deployments where ksmbd is typically disabled by default. The discrepancy between high CVSS and low EPSS suggests this is a defense-in-depth fix rather than an imminent mass-exploitation threat.

Exploit ScenarioDerived

Remote attacker sends specially crafted SMB2_LOCK requests to a ksmbd-enabled server on TCP port 445, targeting error-handling paths in smb2_lock(). By triggering vfs_lock_file() to return unexpected error codes during lock or unlock operations, the attacker forces memory leaks that accumulate until kernel memory exhaustion causes system instability or crash. Alternatively, attacker induces allocation failure during rollback by saturating kernel memory, triggering NULL pointer dereference that immediately crashes the kernel. No public proof-of-concept identified at time of analysis, but attack primitives (malformed SMB lock requests) are well-understood protocol manipulation techniques requiring only standard SMB client libraries.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Apr 27, 2026

Memory exhaustion and kernel crash in Linux kernel's ksmbd SMB server allows remote unauthenticated denial of service via crafted lock requests. The smb2_lock() function contains three critical error-handling defects: memory leaks when vfs_lock_file() returns unexpected errors, stale error propagation in UNLOCK operations, and NULL pointer dereference during rollback when smb_flock_init() allocation fails. CVSS vector indicates network-accessible, low-complexity exploitation requiring no authentication. EPSS score of 0.02% (7th percentile) suggests minimal observed scanning activity, and no KEV listing confirms no widespread exploitation detected. However, the network attack vector (AV:N) and high availability impact (A:H) make this a realistic DoS risk for systems running ksmbd. Vendor patches available across stable kernel series 5.15-6.19.

RemediationAI

Upgrade to patched Linux kernel versions: 5.15.x to latest stable, 6.1.168 or later, 6.6.131 or later, 6.12.80 or later, 6.18.21 or later, 6.19.11 or later, or mainline 7.0+. Patch commits available at https://git.kernel.org/stable/c/aab42f0795620cf0d3955a520f571f697d0f9a2a (mainline) and distribution-specific backports. If immediate patching is infeasible, disable ksmbd service via 'systemctl stop ksmbd' and 'modprobe -r ksmbd' to eliminate attack surface-this breaks SMB file sharing functionality and requires migrating to user-space Samba or alternative protocols. Alternatively, restrict ksmbd network exposure using firewall rules to block TCP ports 445 and 139 from untrusted networks (iptables -A INPUT -p tcp --dport 445 -s untrusted_network -j DROP), though this only reduces attack surface and does not address authenticated threat scenarios if credentials are compromised. Network-level filtering incurs no performance penalty but requires maintaining ACLs as network topology changes. For container environments, ensure base images use patched kernel versions and validate ksmbd module status during security scanning. No application-layer configuration changes mitigate this kernel-level flaw.

Affected VersionsENISA

Linux e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 <aab42f0795620cf0d3955a520f571f697d0f9a2a
Linux patch: 7.0
Linux e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 <3cdacd11b41569ce75b3162142240f2355e04900
Linux e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 <91aeaa7256006d79a37298f5a1df23325db91599
Linux e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 <309b44ed684496ed3f9c5715d10b899338623512
Linux e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 <c9b95ef6f5039f19e46c3a521a4fe1752d91dfe9
Linux patch: 6.12.80
Linux patch: 6.1.168
Linux patch: 6.19.11
Linux e2f34481b24db2fd634b5edb0a5bd0e4d38cc6e9 <cdac6f7e7e428dc70e3b5898ac6999a72ed13993
Linux patch: 6.6.131
Linux 5.15
Linux patch: 6.18.21
Linux patch: 0

Affected Packages

euvd linux no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

This vulnerability affects ksmbd, the in-kernel SMB3 server implementation introduced in Linux 5.15 as a performance-optimized alternative to user-space Samba. The flaw exists in fs/smb/server/smb2pdu.c's smb2_lock() function, which handles SMB2 opportunistic lock and byte-range lock operations. When list_del() detaches a lock structure from the tracking list, three code paths fail to properly manage memory: (1) unexpected vfs_lock_file() errors in non-UNLOCK operations leak both the smb_lock structure and its associated flock, (2) ENOENT returns during UNLOCK operations leak the same structures while propagating stale error codes, and (3) smb_flock_init() allocation failures during rollback cause unchecked NULL dereference when attempting locks_free_lock(). The root causes combine improper resource management after detachment from tracking lists, missing error propagation, and absent NULL validation-patterns typical of CWE-401 (Missing Release of Memory) and CWE-476 (NULL Pointer Dereference), though no CWE was formally assigned. The vulnerability surfaces through the SMB2 protocol's lock management interface, exposing kernel memory management to remote influence.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (416baaa9-dc9f-4396-8d5f-8c081fb06d67) PRIMARY 7.5 HIGH
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
SUSE HIGH

Primary rating from Vendor (416baaa9-dc9f-4396-8d5f-8c081fb06d67).

CVSS VectorVendor: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

Lifecycle Timeline

4
Patch released
Apr 27, 2026 - 23:24 nvd
Patch available
CVSS changed
Apr 27, 2026 - 14:22 NVD
7.5 (HIGH)
Patch available
Apr 22, 2026 - 16:33 EUVD
CVE Published
Apr 22, 2026 - 14:16 nvd
HIGH 7.5

DescriptionCVE.org

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

ksmbd: fix memory leaks and NULL deref in smb2_lock()

smb2_lock() has three error handling issues after list_del() detaches smb_lock from lock_list at no_check_cl:

  1. If vfs_lock_file() returns an unexpected error in the non-UNLOCK

path, goto out leaks smb_lock and its flock because the out: handler only iterates lock_list and rollback_list, neither of which contains the detached smb_lock.

  1. If vfs_lock_file() returns -ENOENT in the UNLOCK path, goto out

leaks smb_lock and flock for the same reason. The error code returned to the dispatcher is also stale.

  1. In the rollback path, smb_flock_init() can return NULL on

allocation failure. The result is dereferenced unconditionally, causing a kernel NULL pointer dereference. Add a NULL check to prevent the crash and clean up the bookkeeping; the VFS lock itself cannot be rolled back without the allocation and will be released at file or connection teardown.

Fix cases 1 and 2 by hoisting the locks_free_lock()/kfree() to before the if(!rc) check in the UNLOCK branch so all exit paths share one free site, and by freeing smb_lock and flock before goto out in the non-UNLOCK branch. Propagate the correct error code in both cases. Fix case 3 by wrapping the VFS unlock in an if(rlock) guard and adding a NULL check for locks_free_lock(rlock) in the shared cleanup.

Found via call-graph analysis using sqry.

Executive ViewAI

Why It Matters

CVE-2026-31477 is a high-severity denial-of-service vulnerability in Linux kernel's ksmbd SMB server that allows unauthenticated remote attackers to crash affected systems via malformed lock requests, potentially disrupting file-sharing services and business continuity for organizations relying on SMB-based file servers or NAS appliances.

Business Impact: High
Compensating Controls

Apply vendor patch to Linux kernel (versions 5.15-6.19); network segmentation restricting ksmbd/SMB port 445 access to trusted internal networks; disable ksmbd service if not required; implement rate-limiting on lock requests at firewall or load-balancer level; monitor for abnormal connection patterns to SMB services.

Threat Intelligence Overview

EPSS Score
0.0%
Top 93% exploitable
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact
High

Priority Score

38
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +38
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A null pointer dereference occurs when a program attempts to access memory through a pointer that has been set to NULL (address 0x0).

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

Vendor StatusVendor

SUSE

Severity: High
Product Status
SUSE Linux Enterprise Desktop 15 SP7 Fixed
SUSE Linux Enterprise Desktop 15 SP7 Fixed
SUSE Linux Enterprise High Availability Extension 15 SP7 Fixed
SUSE Linux Enterprise High Availability Extension 15 SP7 Fixed
SUSE Linux Enterprise High Performance Computing 15 SP7 Fixed

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy