CVE-2026-138996

Not scored yetLast modified Nov 30, 2026

Description

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

seccomp: restore knotif->state when SECCOMP_ADDFD_FLAG_SEND is interrupted

In seccomp_notify_addfd(), when SECCOMP_ADDFD_FLAG_SEND is set in addfd.flags, knotif->state is optimistically transitioned from SECCOMP_NOTIFY_SENT to SECCOMP_NOTIFY_REPLIED before waking the tracee and waiting on kaddfd.completion:

if (addfd.flags & SECCOMP_ADDFD_FLAG_SEND) { knotif->state = SECCOMP_NOTIFY_REPLIED; ... }

If wait_for_completion_interruptible(&kaddfd.completion) is interrupted by a signal before the tracee dequeues the kaddfd request (!list_empty(&kaddfd.list)), seccomp_notify_addfd() removes kaddfd from knotif->addfd and returns -EINTR to the supervisor without having installed the file descriptor.

However, knotif->state is left as SECCOMP_NOTIFY_REPLIED (with knotif->error == 0 and knotif->val == 0). This causes two problems:

1. When the tracee runs in do_user_notif(), it checks if (knotif.state != SECCOMP_NOTIFY_REPLIED) after calling seccomp_handle_addfd(). Because knotif->state is already SECCOMP_NOTIFY_REPLIED, the tracee exits the notification wait loop prematurely and returns 0 from the trapped syscall without the file descriptor ever having been installed.

2. If the supervisor retries SECCOMP_IOCTL_NOTIF_ADDFD or SECCOMP_IOCTL_NOTIF_SEND before the tracee runs, it fails with -EINPROGRESS because knotif->state is no longer SECCOMP_NOTIFY_SENT.

Fix this by restoring knotif->state back to SECCOMP_NOTIFY_SENT if SECCOMP_ADDFD_FLAG_SEND was set and kaddfd was not consumed before the interrupted wait. Also add a seccomp_bpf selftest (user_notification_addfd_send_interrupted) covering this race.

Tested in QEMU against Linux 7.3.0-rc3 using the user_notification_addfd_send_interrupted selftest added in this patch (./seccomp_bpf -t user_notification_addfd_send_interrupted): on the unfixed kernel the test fails because the retry ioctl(listener, SECCOMP_IOCTL_NOTIF_ADDFD, &addfd) returns -EINPROGRESS (-1) and the tracee prematurely exits do_user_notif() with return value 0 instead of FD 42, whereas with this patch applied the test passes.

Metrics

No CVSS score has been published yet.

Affected software

Source: the vendor's advisory (CNA). NVD analysis pending.

No affected versions have been published.

Timeline

Published
Nov 30, 2026
Last modified
Nov 30, 2026
NVD status
Received

Related CVEs from 2026

CVE-2026-138997In the Linux kernel, the following vulnerability has been resolved: signalfd: don't dequeue the forced fatal signals These signals should CVE-2026-138998In the Linux kernel, the following vulnerability has been resolved: i3c: mipi-i3c-hci-pci: Set drvdata before creating LTR sysfs attribute CVE-2026-138999In the Linux kernel, the following vulnerability has been resolved: i3c: mipi-i3c-hci: Bounce short reads irrespective of the IOMMU The coCVE-2026-13904.3The Redirect countdown plugin for WordPress is vulnerable to Cross-Site Request Forgery in all versions up to, and including, 1.0. This is dCVE-2026-139006.5Inappropriate implementation in Chromecast in Google Chrome prior to 150.0.7871.47 allowed a remote attacker who had compromised the rendereCVE-2026-139000In the Linux kernel, the following vulnerability has been resolved: i3c: master: Fix out-of-bounds read in DMA bounce buffer setup When a CVE-2026-139001In the Linux kernel, the following vulnerability has been resolved: cpufreq: CPPC: Create the FIE worker before enabling PCC callbacks cppCVE-2026-139002In the Linux kernel, the following vulnerability has been resolved: ACPI: CPPC: Propagate errors from cross-CPU FFH calls The arm64 and RICVE-2026-139003In the Linux kernel, the following vulnerability has been resolved: crypto: xilinx - clear AES key buffer before freeing it In xilinx_aes_CVE-2026-139004In the Linux kernel, the following vulnerability has been resolved: spi: spi-qpic-snand: publish the ECC context to snandc->qspi qcom_spi_CVE-2026-139005In the Linux kernel, the following vulnerability has been resolved: md/raid5: validate payload size before calculating payload_len Commit CVE-2026-139006In the Linux kernel, the following vulnerability has been resolved: md/raid5: track disks array size to fix extra_page leak on error paths
CVE-2026-138996: Unscored | Vulnix