Microsoft Defender Link Following Local Privilege Escalation (CVE-2026-41091)
by tc4dy · 2026-07-05
- Severity
- High
- CVE
- CVE-2026-41091
- Category
- binary
- Affected product
- Microsoft Defender / Microsoft Malware Protection Engine
- Affected versions
- Microsoft Malware Protection Engine < 1.1.26040.8; Antimalware Platform < 4.18.26040.7
- Disclosed
- 2026-07-05
- Patch status
- unpatched
Tags
Archive entry
intelseclab/poc-archiveMetadata
| Field | Value |
|---|---|
| Date Added | 2026-07-05 |
| Last Updated | 2026-06 |
| Author / Researcher | tc4dy |
| CVE / Advisory | CVE-2026-41091 |
| Category | binary |
| Severity | High |
| CVSS Score | 7.8 (High) — AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H (as stated in source repo) |
| Status | Weaponized |
| Tags | windows, microsoft-defender, link-following, cwe-59, cloud-files-api, ntfs-junction, oplock, privilege-escalation, lpe |
| Related | N/A |
Affected Target
| Field | Value |
|---|---|
| Software / System | Microsoft Defender / Microsoft Malware Protection Engine |
| Versions Affected | Microsoft Malware Protection Engine < 1.1.26040.8; Antimalware Platform < 4.18.26040.7 |
| Language / Platform | C++ (Windows, x64) |
| Authentication Required | Local-only (low-privileged local account) |
| Network Access Required | No (local exploitation; internet access needed only to trigger a VSS snapshot in the researcher’s environment) |
Summary
CVE-2026-41091 is a local privilege escalation vulnerability in Microsoft Defender caused by improper link resolution (CWE-59) during file operations performed with SYSTEM privileges. By racing a Defender-triggered scan against filesystem oplocks, and then substituting a real directory with an NTFS junction pointing at C:\Windows\System32, a low-privileged local attacker can get Defender’s Cloud Files API–backed remediation logic to write an attacker-controlled file into a protected system directory. The repository includes a simplified basic_poc.cpp that demonstrates the oplock/junction-swap algorithm, and a full_poc.cpp that adds Cloud Files API (CfAPI) placeholder creation and COM-based service activation to complete SYSTEM code execution.
Vulnerability Details
Root Cause
Microsoft Defender resolves and later re-opens a working-directory path across multiple steps of a Cloud Files API–driven remediation/quarantine flow without safely pinning the handle, allowing a symlink/junction race (TOCTOU) to redirect the operation onto an arbitrary NTFS junction target such as System32.
Attack Vector
- Attacker creates a working directory and drops a bait file containing an EICAR test string to trigger Defender scanning/remediation on it.
- Attacker requests a batch oplock (
FSCTL_REQUEST_BATCH_OPLOCK) on the bait file and waits for Defender to open it (oplock break), giving the attacker a window of exclusive access. - Attacker renames the original directory out of the way and registers a Cloud Files API sync root, creating a cloud placeholder in its place; a second oplock/break cycle is used to win a race against Defender’s next file access.
- Attacker renames the cloud directory aside and creates an NTFS junction from the original path to
C:\Windows\System32, then lets Defender copy the payload into System32 under a legitimate service binary name. - Attacker triggers activation of the associated Windows service (e.g., Storage Tiers Management) via COM (
CoCreateInstance), causing the planted payload to execute asNT AUTHORITY\SYSTEM.
Impact
A low-privileged local attacker can escalate to NT AUTHORITY\SYSTEM, obtaining full control of the host including arbitrary code execution, credential theft, and persistence.
Environment / Lab Setup
Target: Windows 10/11 or Windows Server 2019/2022 with Microsoft Defender enabled, unpatched (Malware Protection Engine < 1.1.26040.8)
Attacker: Visual Studio 2019/2022 with C++17 toolchain (or CMake), cfapi.lib and ntdll.lib for the full exploit build
Proof of Concept
PoC Script
See
basic_poc.cpp(algorithm demonstration) andfull_poc.cpp(complete exploit chain) in this folder.
| |
full_poc.exe creates a randomly-named working directory, baits Microsoft Defender with an EICAR trigger, wins the oplock/rename race twice to swap in an NTFS junction pointing at System32, copies its payload in as a legitimate-looking service binary, and activates the corresponding Windows service via COM to execute the payload as SYSTEM. basic_poc.exe runs only the oplock/junction-swap algorithm for demonstration without the CfAPI/COM activation steps.
Detection & Indicators of Compromise
Signs of compromise:
- New or modified executables in
System32matching known service binary names (e.g.TieringEngineService.exe) with mismatched hashes/timestamps - Rapid create/rename/junction sequences on a
%TEMP%directory correlated with Defender scan events - Unexpected activation of storage-tiering or other privileged COM services shortly after a low-privileged logon session performs filesystem operations
Remediation
| Action | Detail |
|---|---|
| Primary fix | Update Microsoft Malware Protection Engine to 1.1.26040.8+ / Antimalware Platform to 4.18.26040.7+ (delivered via normal Defender platform/engine updates) |
| Interim mitigation | Restrict local user write access to directories scanned/remediated by Defender where feasible; monitor for oplock-based race patterns and unexpected junction creation targeting System32 |
References
Notes
Mirrored from https://github.com/tc4dy/CVE-2026-41091-PoC-Exploit on 2026-07-05. The source repo’s README uses hype-heavy/clickbait framing (branding the vulnerability “SolarFlare” and displaying a “CISA KEV — actively exploited in the wild” badge); that “actively exploited in the wild” claim is unverified in this mirror and should be treated with skepticism until confirmed against an authoritative source (e.g. CISA’s KEV catalog) rather than cited as fact.
| |