CVE-2026-48574 — Windows Media Remote Code Execution Vulnerability
Executive Summary
Heap-based buffer overflow in Windows Media allows an unauthorized attacker to execute code locally.
Overview
CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H/E:U/RL:O/RC:C
EPSS Score
Affected Products
| Product | KB Article | Severity | Impact | Restart Required |
|---|---|---|---|---|
| Windows 10 Version 1607 for 32-bit Systems | 5094122 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 1607 for x64-based Systems | 5094122 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 1809 for 32-bit Systems | 5094123 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 1809 for x64-based Systems | 5094123 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 21H2 for 32-bit Systems | 5094127 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 21H2 for ARM64-based Systems | 5094127 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 21H2 for x64-based Systems | 5094127 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 22H2 for 32-bit Systems | 5094127 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 22H2 for ARM64-based Systems | 5094127 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 10 Version 22H2 for x64-based Systems | 5094127 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 Version 23H2 for ARM64-based Systems | 5093998 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 Version 23H2 for x64-based Systems | 5093998 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 Version 24H2 for ARM64-based Systems | 5094126 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 Version 24H2 for x64-based Systems | 5094126 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 Version 25H2 for ARM64-based Systems | 5094126 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 Version 25H2 for x64-based Systems | 5094126 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 Version 26H1 for ARM64-based Systems | 5095051 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows 11 version 26H1 for x64-based Systems | 5095051 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2012 | 5094042 (Monthly Rollup) |
Critical | Remote Code Execution | Yes |
| Windows Server 2012 (Server Core installation) | 5094042 (Monthly Rollup) |
Critical | Remote Code Execution | Yes |
| Windows Server 2012 R2 | 5094041 (Monthly Rollup) |
Critical | Remote Code Execution | Yes |
| Windows Server 2012 R2 (Server Core installation) | 5094041 (Monthly Rollup) |
Critical | Remote Code Execution | Yes |
| Windows Server 2016 | 5094122 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2016 (Server Core installation) | 5094122 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2019 | 5094123 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2019 (Server Core installation) | 5094123 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2022 | 5094128 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2022 (Server Core installation) | 5094128 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2025 | 5094125 (Security Update) |
Critical | Remote Code Execution | Yes |
| Windows Server 2025 (Server Core installation) | 5094125 (Security Update) |
Critical | Remote Code Execution | Yes |
Patches
| Article | Type | Restart |
|---|---|---|
5094122 |
Security Update | Yes |
5094123 |
Security Update | Yes |
5094127 |
Security Update | Yes |
5093998 |
Security Update | Yes |
5094126 |
Security Update | Yes |
5095051 |
Security Update | Yes |
5094042 |
Monthly Rollup | Yes |
5094041 |
Monthly Rollup | Yes |
5094128 |
Security Update | Yes |
5094125 |
Security Update | Yes |
Patch Diff
Heap buffer overflow (CWE-122) via a store-before-bounds-check in the Windows Media Foundation MKV source mfmkvsrcsnk.dll MkvMfStreamVideoHEVC::GetMFMediaType, Critical RCE on opening a crafted HEVC media file (UI:R). Parsing the HEVC track CodecPrivate (hvcC), the function records each parameter-set NAL length in a table at this+0x1E0 that is 0x800 bytes = 512 DWORD entries (valid index 0-511). PRE: it wrote *(this+0x1e0 + v3*4) = nalUnitLength+4 FIRST, then incremented v3 and only afterward checked v3 > 0x200. When the index reaches 512 (already out of range) it executes table[512]=len+4, a 4-byte write immediately past the 0x800-byte table, before the check stops parsing. The written value is nalUnitLength+4 big-endian (4..0x10003), attacker-influenced; the NAL type is checked once per array (not per NAL), so a single parameter-set array with numNalus=513 gives 513 store targets and ~1KB CodecPrivate drives the index to 512. Diff of mfmkvsrcsnk.dll 10.0.26100.8328 -> .8655 (Jun 9 2026, KB5094126) confirms the fix: the bound is now checked before the write and the store is guarded by (index < 0x200), so the out-of-bounds table[512] write no longer occurs. Unconditional fix (no CFR flag).
| Function | Address | Change | Note |
|---|---|---|---|
MkvMfSourceLib::MkvMfStreamVideoHEVC::GetMFMediaType |
code change |
code (bounds check moved before the table store) | Pre: *(this+0x1e0 + v3*4) = nalUnitLength+4; v3++; if (0x200 < v3) fail -> table[512] written once before the check. Post: bound (0x200 < idx) checked up front and the store guarded by (idx < 0x200), eliminating the OOB write at index 512. Table at this+0x1E0 is 0x800 bytes / 512 DWORD entries. |
Root Cause Analysis
CVE-2026-48574 — Windows Media mfmkvsrcsnk.dll HEVC Parameter-Set Table Overflow: Store-Before-Bounds-Check in MkvMfStreamVideoHEVC::GetMFMediaType
Summary
| Product | Windows — mfmkvsrcsnk.dll (Media Foundation Matroska/MKV source; HEVC track) |
| CVE ID | CVE-2026-48574 |
| Impact | Remote Code Execution |
| MSRC severity | Critical |
| CVSS | 7.8 / 6.8 — CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H/E:U/RL:O/RC:C |
| CWE | CWE-122: Heap-based Buffer Overflow (off-by-one store-before-check) |
| Delivery | A crafted MKV/HEVC media file opened/played by the user (UI:R) |
| KB / Fixed build | KB5094126 — mfmkvsrcsnk.dll 10.0.26100.8655 (Win11 24H2 x64) |
| Patch Date | June 9, 2026 (2026-Jun) |
| Pre-patch binary | mfmkvsrcsnk.dll 10.0.26100.8328 — SHA256 83a8fe556cc10566099510172cbf4cfea0c28cb4671f771c3519b4c247973a60 |
| Post-patch binary | mfmkvsrcsnk.dll 10.0.26100.8655 — SHA256 8a610beeeb0d5469c6923dc6131d40a2e16d66fc97ddaf477f7869408026e5fe |
| Feature flag | None — the fix is an unconditional reorder |
| Exploitability | Exploitation Less Likely; not publicly disclosed; not exploited (per MSRC) |
Product Description
mfmkvsrcsnk.dll is the Media Foundation Matroska (MKV) source/sink. For an HEVC
track, MkvMfStreamVideoHEVC::GetMFMediaType parses the track’s CodecPrivate
(the hvcC structure) — a set of parameter-set NAL units — and records each NAL’s
length in a length table at this + 0x1E0. That table is 0x800 bytes, so
on a DWORD basis it holds 512 entries (valid index 0–511).
Vulnerability Summary
While parsing HEVC CodecPrivate, the parser wrote the length into the table
before checking the index bound:
// GetMFMediaType (10.0.26100.8328) — PRE-PATCH, from our diff
*(uint *)(*(longlong *)(this + 0x1e0) + v3 * 4) = nalUnitLength + 4; // *** store FIRST ***
v3++;
if (0x200 < v3) { MFMediaType = -1072875842; } // *** bound check AFTER ***
When the store index reaches 512 (already out of range), the code executes
table[512] = nalUnitLength + 4 — a 4-byte write immediately past the
0x800-byte table — before the v3 > 0x200 check increments and stops parsing.
The check exists but runs one iteration too late.
The written value is nalUnitLength + 4 in big-endian, attacker-influenced
(range 4..0x10003). Because the parser checks the NAL type only once per array
(not per NAL), a single parameter-set array with numNalus = 513 yields 513 store
targets, and ~1 KB of CodecPrivate is enough to drive the index to 512 — a
controllable 4-byte heap overflow right behind the table (CWE-122). As HEVC
media is processed by Media Foundation on simply opening a file, this is a
Critical RCE (UI:R).
Prerequisites and Constraints
- The victim opens / plays a crafted MKV file with an HEVC track (
UI:R,PR:N). CodecPrivatedeclares a parameter-set array withnumNalus≥ 513 so the length table index reaches 512.- Result: a 4-byte, partially attacker-controlled write just past the
0x800-byte heap table.
Vulnerability Details
Root Cause
The bounds check on the parameter-set length-table index was performed after
the write, so the first out-of-range index (512) still executed one 4-byte store
past the end of the fixed 0x800-byte table.
The patch (confirmed — diff, .8328 → .8655)
The fix simply reverses the order: the index is bounds-checked (and the store
guarded by index < 0x200) before writing:
// GetMFMediaType (10.0.26100.8655) — PATCHED, from our diff
if (0x200 < uVar10) { /* ...fail path... */ } // bound checked up front
...
if ((uint)uVar15 < 0x200) // *** guard the store ***
*(uint *)(*(longlong *)(this + 0x1e0) + uVar15 * 4) = uVar10 + 4;
With the store now conditioned on index < 0x200 (512) and the failure detected
before writing, the out-of-bounds table[512] write no longer occurs. Our diff of
mfmkvsrcsnk.dll 10.0.26100.8328 → .8655 shows the pre-patch unconditional store
(table[idx*4] = len+4) followed by a late 0x200 < idx check replaced with the
bound check + idx < 0x200-guarded store. Unconditional fix (no feature flag).
Patch Completeness Assessment
The reorder removes the single off-by-one write; the table remains 512 entries and
oversized numNalus now fails cleanly.
Detection Guidance
Behavioural. MKV/HEVC files whose hvcC CodecPrivate declares an abnormally
large parameter-set count (numNalus ≥ 513); heap-corruption crashes in
mfmkvsrcsnk!MkvMfStreamVideoHEVC::GetMFMediaType while resolving the media type
on unpatched builds.
References
- MSRC advisory — CVE-2026-48574 (Windows Media Remote Code Execution), released 2026-06-09, KB5094126.
- Full binary diff:
/data/patch_diffs/mfmkvsrcsnk_dll-cve-2026-48574-ghidriff.md
Attack Path
HEVC CodecPrivate with numNalus=513 makes the length table store one 4-byte entry past its 512-slot end before the check fires
Derived from the patch delta: the checks added by the vendor identify which fields crossed a trust boundary unvalidated. Reachability and privilege are taken from the call chain in the RCA report.
Exploits & PoC
Detection Rules
Acknowledgments
cyanbamboo and b2ahex
Anonymous
Kyeongmin Kim (@hareh4ru)