Skip to main content

Linux Kernel CVE-2025-40012

HIGH
2025-10-20 416baaa9-dc9f-4396-8d5f-8c081fb06d67
7.8
CVSS 3.1 · Vendor: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
Share

Severity by source

Vendor (416baaa9-dc9f-4396-8d5f-8c081fb06d67) PRIMARY
7.8 HIGH
AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
vuln.today AI
7.0 HIGH

Local unprivileged SMC-socket access (AV:L/PR:L); reliable memory corruption needs to win a free-vs-splice race, so AC:H rather than AC:L, with full UAF C/I/A impact.

3.1 AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
4.0 AV:L/AC:H/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
SUSE
4.7 MEDIUM
AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H

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

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

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

Lifecycle Timeline

2
Analysis Generated
Jul 30, 2026 - 08:00 vuln.today
CVE Published
Oct 20, 2025 - 16:15 cve.org
HIGH 7.8

DescriptionCVE.org

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

net/smc: fix warning in smc_rx_splice() when calling get_page()

smc_lo_register_dmb() allocates DMB buffers with kzalloc(), which are later passed to get_page() in smc_rx_splice(). Since kmalloc memory is not page-backed, this triggers WARN_ON_ONCE() in get_page() and prevents holding a refcount on the buffer. This can lead to use-after-free if the memory is released before splice_to_pipe() completes.

Use folio_alloc() instead, ensuring DMBs are page-backed and safe for get_page().

WARNING: CPU: 18 PID: 12152 at ./include/linux/mm.h:1330 smc_rx_splice+0xaf8/0xe20 [smc] CPU: 18 UID: 0 PID: 12152 Comm: smcapp Kdump: loaded Not tainted 6.17.0-rc3-11705-g9cf4672ecfee #10 NONE Hardware name: IBM 3931 A01 704 (z/VM 7.4.0) Krnl PSW : 0704e00180000000 000793161032696c (smc_rx_splice+0xafc/0xe20 [smc]) R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:3 CC:2 PM:0 RI:0 EA:3 Krnl GPRS: 0000000000000000 001cee80007d3001 00077400000000f8 0000000000000005 0000000000000001 001cee80007d3006 0007740000001000 001c000000000000 000000009b0c99e0 0000000000001000 001c0000000000f8 001c000000000000 000003ffcc6f7c88 0007740003e98000 0007931600000005 000792969b2ff7b8 Krnl Code: 0007931610326960: af000000 mc 0,0 0007931610326964: a7f4ff43 brc 15,00079316103267ea #0007931610326968: af000000 mc 0,0 >000793161032696c: a7f4ff3f brc 15,00079316103267ea 0007931610326970: e320f1000004 lg %r2,256(%r15) 0007931610326976: c0e53fd1b5f5 brasl %r14,000793168fd5d560 000793161032697c: a7f4fbb5 brc 15,00079316103260e6 0007931610326980: b904002b lgr %r2,%r11 Call Trace: smc_rx_splice+0xafc/0xe20 [smc] smc_rx_splice+0x756/0xe20 [smc]) smc_rx_recvmsg+0xa74/0xe00 [smc] smc_splice_read+0x1ce/0x3b0 [smc] sock_splice_read+0xa2/0xf0 do_splice_read+0x198/0x240 splice_file_to_pipe+0x7e/0x110 do_splice+0x59e/0xde0 __do_splice+0x11a/0x2d0 __s390x_sys_splice+0x140/0x1f0 __do_syscall+0x122/0x280 system_call+0x6e/0x90 Last Breaking-Event-Address: smc_rx_splice+0x960/0xe20 [smc] ---[ end trace 0000000000000000 ]---

AnalysisAI

Use-after-free and kernel WARNING in the Linux kernel's SMC (Shared Memory Communications) subsystem allows a local user to trigger memory corruption via the splice() path on an SMC socket. The smc_lo_register_dmb() loopback path allocates DMB buffers with kzalloc() (kmalloc memory, not page-backed), which are later handed to get_page() in smc_rx_splice(); this fires WARN_ON_ONCE() and can leave the buffer freed before splice_to_pipe() completes, creating a use-after-free. CVSS 7.8 (local, C:H/I:H/A:H); EPSS is low (0.22%, 13th percentile) and there is no public exploit identified at time of analysis.

Technical ContextAI

SMC (Shared Memory Communications, RFC 7609) is a Linux kernel network protocol family that accelerates TCP-like traffic over RDMA (SMC-R) or shared memory (SMC-D), historically tied to IBM Z / s390 hardware but also usable via a software loopback device (smc_lo). Data moves through DMBs (Direct Memory Buffers). The bug is in the loopback DMB registration: smc_lo_register_dmb() used kzalloc(), returning slab/kmalloc memory that is not backed by a struct page in a way get_page() accepts. When smc_rx_splice() zero-copies received data into a pipe it calls get_page() on those buffers, tripping WARN_ON_ONCE() in include/linux/mm.h and failing to take a proper refcount - so the underlying memory can be released while splice_to_pipe() still references it. Root-cause class is a use-after-free (CWE-416, though the feed lists CWE as N/A) stemming from mixing non-page-backed slab memory with the page-refcount API. The fix replaces kzalloc() with folio_alloc(), guaranteeing page-backed buffers safe for get_page().

Affected ProductsAI

The affected product is the Linux kernel SMC networking subsystem (net/smc), reproduced here on kernel 6.17.0-rc3 running under z/VM 7.4.0 on IBM Z (3931/z16) hardware, though the code path is not architecture-restricted. No CPE strings were provided in the intelligence feed, so exact affected version ranges are not enumerated; the three stable-tree fix commits (git.kernel.org/stable/c/14fc4fdae42e34d7ee871b292ac2ecc61c2c5de7, .../a35c04de2565db191726b5741e6b66a35002c652, and .../d5411685dc2f6ac7bdf01a0a204d56cae38c6cf6) indicate multiple stable branches received backports. Versions predating these commits that include the smc_lo loopback DMB support are affected; consult your distribution's kernel changelog to map these commit hashes to your shipped kernel.

RemediationAI

Upstream fix available (PR/commit); released patched version not independently confirmed - apply the kernel update that incorporates the change replacing kzalloc() with folio_alloc() in smc_lo_register_dmb(), tracked by stable commits git.kernel.org/stable/c/14fc4fdae42e34d7ee871b292ac2ecc61c2c5de7, .../a35c04de2565db191726b5741e6b66a35002c652 and .../d5411685dc2f6ac7bdf01a0a204d56cae38c6cf6; pull the corresponding fixed build from your distribution once it maps these commits to a released kernel package. If you cannot patch immediately and do not use SMC, a concrete compensating control is to prevent the module from loading - blacklist the smc module (e.g. an /etc/modprobe.d entry with 'install smc /bin/true') so the vulnerable code path is never reachable; the trade-off is that any workload relying on SMC/SMC-D acceleration will fall back to regular TCP. Where SMC is required, restrict which local users can create AF_SMC sockets and avoid exposing the loopback DMB path to untrusted local accounts until patched.

Vendor StatusVendor

SUSE

Severity: Moderate
Product Status
Container suse/sl-micro/6.0/baremetal-os-container:latest Container suse/sl-micro/6.0/kvm-os-container:latest Container suse/sl-micro/6.0/rt-os-container:latest Container suse/sl-micro/6.0/toolbox:latest Affected
Container suse/sl-micro/6.0/base-os-container:latest Image SLE-Micro Image SLE-Micro-Azure Image SLE-Micro-BYOS Image SLE-Micro-BYOS-Azure Image SLE-Micro-BYOS-EC2 Image SLE-Micro-BYOS-GCE Image SLE-Micro-EC2 Image SLE-Micro-GCE Affected
Image SL-Micro-Default Image SL-Micro-Default-SelfInstall Image SL-Micro-Default-encrypted Image SL-Micro-Default-qcow Image SUSE-Multi-Linux-Manager-Server-EC2-llc Image SUSE-Multi-Linux-Manager-Server-EC2-ltd Affected
Image SLES-Azure-3P Image SLES-Azure-Basic Image SLES-Azure-Standard Image SLES-BYOS-Azure Image SLES-BYOS-EC2 Image SLES-BYOS-GCE Image SLES-CHOST-BYOS-Aliyun Image SLES-CHOST-BYOS-Azure Image SLES-CHOST-BYOS-EC2 Image SLES-CHOST-BYOS-GCE Image SLES-CHOST-BYOS-GDC Image SLES-CHOST-BYOS-SAP-CCloud Image SLES-EC2 Image SLES-EC2-ECS Image SLES-GCE Image SLES-GCE-3P Image SLES-Hardened-BYOS-Azure Image SLES-Hardened-BYOS-EC2 Image SLES-Hardened-BYOS-GCE Image SLES-SAPCAL-Azure Image SLES-SAPCAL-EC2 Image SLES-SAPCAL-GCE Affected
Image SLES-SAP-Azure Image SLES-SAP-Azure-3P Image SLES-SAP-BYOS-Azure Image SLES-SAP-BYOS-EC2 Image SLES-SAP-BYOS-GCE Image SLES-SAP-EC2 Image SLES-SAP-GCE Image SLES-SAP-GCE-3P Affected

Share

CVE-2025-40012 vulnerability details – vuln.today

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