CVE-2026-99701: mm/ksm: fix userfaultfd protection during merge and unmerge

Published Nov 20, 2026
·
Updated

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

mm/ksm: fix userfaultfd protection during merge and unmerge

KSM loses userfaultfd protection when replacepage() builds a new PTE from vma->vmpageprot. Dropping its uffd bit lets a subsequent write go through ordinary COW instead of userfaultfd write protection handling. For RWP, a merged page also becomes readable without faulting.

Keeping the uffd bit and restoring PAGENONE fixes merging, but we also have to handle unmerging. An existing KSM page can be protected with RWP before MADVUNMERGEABLE, so unmerging already needs fixing independently of preserving RWP during merging.

Unsharing replaces a shared page with a private one and should leave userfaultfd protection in place, as dowppage() already does for write protection. Currently, an unshare fault reaches douffdrwp() before it can proceed to dowppage().

- With synchronous RWP, handleuserfault() returns VMFAULTSIGBUS. breakksm() then reports success with a KSM page still merged.

- With asynchronous RWP, protection is cleared before unsharing.

Preserve the uffd bit when merging, and restore PAGENONE for RWP. Let FAULTFLAGUNSHARE skip RWP fault handling and keep PAGENONE on each private copy as well. Unsharing can then complete with RWP still armed for a subsequent access.

Affected Software

5 affected componentsFixes available
linux/kernel>=5.7.0<7.3.5
7.3.5
debian/linux*
debian/linux*
debian/linux*
debian/linux<=6.1.176-1, <=6.1.192-2, <=6.12.107-1, <=6.12.117-1, <=7.3.4-1
7.3.5-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 7.3.5
  2. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 7.3.5-1

Event History

Nov 20, 2026
CVE Published
via MITRE·05:50 AM
Data Sourced
via MITRE·05:50 AM
Description
Data Sourced
via OSV·05:50 AM
DescriptionAffected Software
Data Sourced
via NVD·06:18 AM
Description

Frequently Asked Questions

1

Which systems are exposed to this issue?

Linux kernel systems that use Kernel Samepage Merging (KSM) together with userfaultfd write protection, including RWP, are affected. The described failure paths involve merging or unmerging KSM pages that have userfaultfd protection.

2

What conditions are needed to trigger the problem?

The issue requires interaction between KSM page sharing or unsharing and userfaultfd protection. Relevant operations include merging a page, applying RWP to an existing KSM page before MADV_UNMERGEABLE, or unsharing a protected shared page.

3

What can happen when the issue is triggered?

Userfaultfd protection can be lost, allowing a write to take the ordinary copy-on-write path rather than userfaultfd write-protection handling. For RWP, a merged page may become readable without faulting; synchronous RWP unsharing can also report success while the page remains KSM-merged.

4

Is there a workaround if the kernel update cannot be applied immediately?

The provided information identifies the affected interaction as KSM with userfaultfd write protection. Avoiding that combination, including applying RWP to KSM pages before MADV_UNMERGEABLE, avoids the described paths.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203