Skip to main content
Meet us at Black Hat USA 2026— Las Vegas, August 1–6Book a Meeting
Mallory
HighPublic exploit

Use-after-free race in Linux kernel DRM change_handle

IdentifiersCVE-2026-46215CWE-416· Use After Free

CVE-2026-46215 is a race condition in the Linux kernel DRM subsystem's handle-changing logic, specifically in change_handle. During the ioctl, a GEM object could transiently be associated with two IDR handle entries at the same time. If a concurrent gem_close occurred during that window, it could delete the object and remove one handle while leaving the other handle dangling. That stale handle could then be dereferenced, resulting in a kernel use-after-free. The fix mirrors the handle-release sequencing used by gem_close: first replace the old handle entry with NULL via idr_replace, and only later, after PRIME-related operations succeed, actually close the old handle. The issue is described as analogous to an earlier race addressed in drm_gem_handle_create_tail(), though here the relevant concurrency is with drm_prime while change_handle holds the PRIME lock for the duration.

Share:
For your environment

Are you exposed to this one?

Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.

ANALYST BRIEF

Impact, mitigation & remediation

What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Successful exploitation can trigger a use-after-free in kernel-space DRM/GEM object handling. The direct consequences include kernel memory corruption and system instability, typically leading to denial of service such as a kernel crash. Because the flaw is in kernel memory lifetime management, a sufficiently capable attacker may also be able to leverage it for more advanced exploitation, potentially including privilege escalation, although that depends on the reachable attack surface, allocator behavior, and the surrounding environment.

Mitigation

If you can’t patch tonight, do this now.

If immediate patching is not possible, reduce exposure to the DRM ioctl attack surface by limiting access to DRM device nodes to trusted local users and workloads only. Minimize untrusted access to GPU/DRM interfaces, including from containers or sandboxed environments that expose /dev/dri devices. Where operationally feasible, disable or restrict affected graphics/DRM functionality until patched. These are only exposure-reduction measures; the definitive mitigation is to install the fixed kernel.

Remediation

Patch, then assume compromise.

Update to a Linux kernel version containing the upstream fix for CVE-2026-46215. The remediation is to modify DRM change_handle so that the old handle is replaced with NULL before the PRIME swap and only closed after the relevant operations complete successfully, eliminating the transient double-handle state that enabled the race. Apply the vendor or distribution kernel update that includes this patch.
PUBLIC EXPLOITS

Exploits

1 valid exploit after Mallory filtered fakes, detection scripts, and README-only repos.

VALID 1 / 1 TOTALView more in app
CVE-2026-46215-POCMaturityPoCVerified exploit

Repository contains a complete local privilege escalation exploit for CVE-2026-46215, a Linux kernel DRM GEM use-after-free in drm_gem_change_handle_ioctl. Structure is minimal: README.md documents the bug, affected/fixed versions, exploit chain, prerequisites, and expected output; poc.c implements the exploit in C; run_exploit.sh builds a static PoC plus a tiny initramfs and boots a vulnerable kernel in QEMU for reproduction. The exploit is not a scanner or detection script. It is an operational end-to-end LPE chain. In poc.c, two threads race DRM_IOCTL_GEM_CHANGE_HANDLE against DRM_IOCTL_GEM_CLOSE on a GEM object to create a dangling handle. The freed slab slot is reclaimed with sprayed pipe_buffer objects. A driver-specific info ioctl (virtio_gpu or nouveau) is then used to leak a kernel pointer from overlapped pipe_buf_ops, giving a KASLR bypass. Next, DRM_IOCTL_GEM_FLINK is used so the GEM object's name field overlaps pipe_buf flags, setting PIPE_BUF_FLAG_CAN_MERGE. Finally, writes to the prepared pipes are merged into the page cache of /etc/passwd, overwriting the root entry and removing its password field, yielding passwordless root. The code then verifies the file modification and spawns a shell. The bash wrapper is a reproducibility harness rather than the exploit itself. It compiles the PoC statically, creates a helper that drops to uid/gid 1000, builds an initramfs with busybox, creates a read-only /etc/passwd, and boots QEMU with virtio-gpu-pci, KVM, and nokaslr. Inside the guest it waits for /dev/dri/card0, chmods /dev/dri/* to make the device accessible, runs the exploit as an unprivileged user, and prints /etc/passwd before and after. Overall purpose: demonstrate reliable exploitation of the DRM GEM handle UAF to achieve unprivileged root on vulnerable Linux kernels with compatible DRM drivers.

0xCyberstanDisclosed Jun 18, 2026markdownclocalfile
EXPOSURE SURFACE

Affected products & vendors

Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.

VendorProductType
LinuxLinux Kerneloperating_system

Vendor-confirmed product mapping. Mallory continuously reconciles this list against your asset inventory.

ACTIVITY FEED

Recent activity

7 sources tracked across advisories and community write-ups. News coverage will land here when it surfaces.

No news coverage yet. Advisories and community discussion only.

What this page doesn’t show

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, which detections to deploy, and what to do tonight.
Exposure mapping

Query your assets running an affected version, and investigate the blast radius.

Threat actor evidence

Every observed campaign linking this CVE to a named adversary.

Associated malware

Malware families riding this exploit, with evidence and IOCs.

Detection signatures

YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.

Vendor-by-vendor mapping

Cross-references every affected SKU, including bundled OEM variants.

Social activity7

Community discussion across Reddit, Mastodon, and other social sources.