Skip to content
This page tracks the Debian fix status. The vulnerability itself is described on the main CVE page. View CVE-2025-40040 →
Unrated

Vulnerability in linux

DEBIAN-CVE-2025-40040 First seen on SecPulse

Auto-generated summary

Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.

A vulnerability tracked as DEBIAN-CVE-2025-40040 has been found in linux.
Attackers can target a specific entry point like VM_MERGEABLE over the network to misuse the product.
Risk of unauthorized operations or information disclosure.
What to do: upgrade linux to 6.1.158-1 or later.
If unsure, ask your IT team or search "linux DEBIAN-CVE-2025-40040" on the vendor's site.

DEBIAN-CVE-2025-40040 (linux)
Attack vector: local / no user interaction
Attack surface: VM_MERGEABLE
Patched: 6.1.158-1 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.

What is the problem

A vulnerability (unclassified) exists in linux. Attackers reach the vulnerable code path via VM_MERGEABLE.

Affected scope

Check the vendor advisory for the affected versions of linux. Attack surface: VM_MERGEABLE.

Severity

Severity: ?. Risk of unauthorized operations or information disclosure.

How to fix

Update to 6.1.158-1.

Workaround

Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.

Detection

Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'linux' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.

Response actions

Concrete steps and command examples for SOC/SRE teams to execute in order

  1. 1
    Identify exposureidentify
    grep -r 'linux' . | grep -v node_modules

    リポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で linux を grep し、稼働しているサービス・バージョンを把握する。

  2. 2
    Apply patchpatch
    Upgrade linux to 6.1.158-1

    ステージング環境で 6.1.158-1 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。

  3. 3
    Post-deployment verificationverify
    Confirm patched version is live in production

    パッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。

Affected packages

PackageAffected → Fixed
Debian:12linux
< 6.1.158-1→ 6.1.158-1
Debian:13linux
< 6.12.57-1→ 6.12.57-1
Debian:14linux
< 6.17.6-1→ 6.17.6-1
Debian:11linux-6.1
< 6.1.158-1~deb11u1→ 6.1.158-1~deb11u1
Original description The description as published by the source.

In the Linux kernel, the following vulnerability has been resolved: mm/ksm: fix flag-dropping behavior in ksm_madvise syzkaller discovered the following crash: (kernel BUG) [ 44.607039] ------------[ cut here ]------------ [ 44.607422] kernel BUG at mm/userfaultfd.c:2067! [ 44.608148] Oops: invalid opcode: 0000 [#1] SMP DEBUG_PAGEALLOC KASAN NOPTI [ 44.608814] CPU: 1 UID: 0 PID: 2475 Comm: reproducer Not tainted 6.16.0-rc6 #1 PREEMPT(none) [ 44.609635] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 44.610695] RIP: 0010:userfaultfd_release_all+0x3a8/0x460 [ 44.617726] Call Trace: [ 44.617926] [ 44.619284] userfaultfd_release+0xef/0x1b0 [ 44.620976] __fput+0x3f9/0xb60 [ 44.621240] fput_close_sync+0x110/0x210 [ 44.622222] __x64_sys_close+0x8f/0x120 [ 44.622530] do_syscall_64+0x5b/0x2f0 [ 44.622840] entry_SYSCALL_64_after_hwframe+0x76/0x7e [ 44.623244] RIP: 0033:0x7f365bb3f227 Kernel panics because it detects UFFD inconsistency during userfaultfd_release_all(). Specifically, a VMA which has a valid pointer to vma->vm_userfaultfd_ctx, but no UFFD flags in vma->vm_flags. The inconsistency is caused in ksm_madvise(): when user calls madvise() with MADV_UNMEARGEABLE on a VMA that is registered for UFFD in MINOR mode, it accidentally clears all flags stored in the upper 32 bits of vma->vm_flags. Assuming x86_64 kernel build, unsigned long is 64-bit and unsigned int an…

Source: OSV.dev (Open Source Vulnerabilities) OSV

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details