Windows Media Player DLL Hijack -- Local Privilege Escalation (CVE-2026-21508)
Published: 2026-08-16 • Researcher: 0xc4r
- Severity
- High
- CVE
- CVE-2026-21508
- Category
- binary
- Affected product
- Microsoft Windows Media Player / WUDFHost.exe
- Affected versions
- Windows 11 (pre-patch)
- Disclosed
- 2026-08-16
- Patch status
- Patched
Tags
References
Archive entry
intelseclab/poc-archiveOn this page
Metadata
| Field | Value |
|---|---|
| Date Added | 2026-08-16 |
| Last Updated | 2026-08-16 |
| Author / Researcher | 0xc4r |
| CVE / Advisory | CVE-2026-21508 |
| Category | binary |
| Severity | High |
| CVSS Score | 7.8 (local privilege escalation) |
| Status | Patched |
| Tags | windows, dll-hijack, lpe, privilege-escalation, media-player, wudfhost, session0, com-hijack, CVE-2026-21508 |
Affected Target
| Field | Value |
|---|---|
| Software / System | Microsoft Windows Media Player / WUDFHost.exe |
| Versions Affected | Windows 11 (pre-patch) |
| Language / Platform | C++ (DLL source), Batch (setup), Visual Studio project |
| Authentication Required | Local unprivileged user |
| Network Access Required | None – local exploitation |
Summary
CVE-2026-21508 is a DLL hijacking vulnerability that achieves Session 0 privilege escalation on Windows 11. WUDFHost.exe loads CrossDevice.Streaming.Source.dll from the user-writable path C:\ProgramData\CrossDevice\. By planting a malicious DLL and manipulating COM CLSID registry entries under HKCU, an unprivileged user redirects WUDFHost.exe to load the DLL in a privileged context when Windows Media Player triggers the driver framework. The DLL calls RevertToSelf() to drop impersonation and spawns an elevated cmd.exe.
Vulnerability Details
Root Cause
WUDFHost.exe performs COM object instantiation via SHCoCreateInstance using CLSIDs that can be redirected through per-user HKCU registry entries. A low-privilege user can hijack the CLSID chain to force WUDFHost.exe to load an arbitrary DLL from a user-writable location. Adding a ShellFolder key bypasses verclsid.exe validation.
Attack Flow
- DLL placement: Copy crafted DLL to
C:\ProgramData\CrossDevice\CrossDevice.Streaming.Source.dll - COM hijack: Registry entries redirect CLSID
{F5FB2C77-...}Instance to{E9F83CF2-...} - Validation bypass:
ShellFolderkey makes WUDFHost callCoCreateInstancedirectly - Trigger: Launch Windows Media Player with USB media present
- Escalation: DLL calls
RevertToSelf()and spawns elevated cmd.exe in Session 0
Impact
- Local privilege escalation on Windows 11
- Elevated command execution in Session 0
- Requires local user session and USB flash drive
Environment / Lab Setup
Requirements:
- Windows 11 (pre-patch)
- Visual Studio (build DLL from source)
- USB flash drive with at least one .jpg file
- Local unprivileged user session
1. Build Session0_CMD project (Release, x64) in Visual Studio
2. Attach USB flash drive
3. Run: SETUP.bat F:\ (F:\ = USB drive letter)
4. Follow WMP setup if promptedProof of Concept
Source files mirrored from 0xc4r/CVE-2026-21508_POC.
Key Files
| File | Purpose |
|---|---|
| Session0_CMD/dllmain.cpp | DLL source – RevertToSelf() + spawn elevated cmd.exe (47 lines) |
| SETUP.bat | Copies DLL, creates registry keys, triggers wmplayer.exe |
| alps.jpg | Stock photograph for USB media detection |
Exploit Code (dllmain.cpp core)
| |
Expected Outcome
After SETUP.bat and WMP activation, Process Explorer shows cmd.exe as child of WUDFHost.exe running at elevated integrity in Session 0.
Detection and Indicators of Compromise
Remediation
| Action | Detail |
|---|---|
| Patch | Apply Microsoft security update for CVE-2026-21508. |
| Workaround | Monitor writes to C:\ProgramData\CrossDevice. Audit HKCU COM registrations. |
| Verification | Check for unauthorized DLLs in CrossDevice directory. Verify Windows Update status. |
References
Notes
All source files screened. DLL project is a simple C++ DLL (47 lines) calling RevertToSelf() and CreateProcessA. SETUP.bat creates two registry keys. alps.jpg is a stock landscape photograph (3.3MB). No pre-compiled DLL binaries – must build from Visual Studio source. No obfuscation, no remote connections, no network activity. Tested for Windows 11.