CVE-2026-112611/112610: CoreGraphics PDF out-of-bounds writes (fixed in iOS 27.2) — fix-diff analysis, on-device proof, methodology, and PoC generator scripts. No prebuilt PoCs, no crash reports.
This repository documents two out-of-bounds write vulnerabilities in CoreGraphics' PDF stack, both fixed in iOS 27.2 (24B115) and credited in Apple's security advisory HT149230 (CVE-2026-112611, CVE-2026-112610):
.ips files
are intentionally withheld; the receipts in analysis/on-device-proof.md are the
technical facts only.Both CVEs are already fixed and publicly credited by Apple — to Anna Groza (@pwnlambda) of Calif.io and others (CVE-2026-112611) and Nik Tsytsarkin (CVE-2026-112610). This repo adds the missing public artifact: where exactly the bugs were, how the fix closes them, and a reproducible crash oracle (as a generator script — no pre-built PoC files).
| Site 1 — Type 5 (lattice-form Gouraud) shading | Site 2 — CMap /UseCMap recursion | |
|---|---|---|
| CVE | CVE-2026-112611 (probable; see note) | CVE-2026-112610 (probable; see note) |
| Class | OOB write of attacker-chosen doubles, stack VLA overrun | OOB write up the stack via unclamped codespace length |
| Trigger | /Sh1 sh content-stream operator — fires on any page render (preview/thumbnail), no fonts, no text, no user interaction | Type-0 (CID) text rendering/extraction with an embedded CMap |
| Pre-fix | _cg_shading_type5_draw runs CGFunctionEvaluate per mesh vertex: R function outputs (R = the /Function's /Range dimension) written into a record with space for nc colorspace components | _cmap_convert recursion passes the outer codespace length L (accepted up to 255) into out-slots sized for exactly one result (2 B code / 8 B len) |
| Fix (27.2) | Parse-time gate range_dim == nc && nc <= 4 + CG-SEC-187882049 log; draw code byte-identical → gate-only fix | min(L,4) clamp + out-slot re-layout + CG-SEC-187882136 log |
| On-device result | Proven: deterministic EXC_BAD_ACCESS, fault 0x3ff000000000001c = the bit pattern of the PDF-chosen double 1.0 (0x3ff0000000000000) + 0x1c — attacker value control | Vehicle refuted for embedded CMaps (three independent reachability blockers, see analysis) — the credited researcher's actual vehicle is presumably different |
Note on CVE assignment. Apple credits two OOB-write fixes under CoreGraphics and the 27.2 diff contains exactly two new bounds checks — a 1:1 correspondence. Which check is which CVE is not statically determinable; the assignment above is our ranking (the shading site is the stronger 1-click primitive), not evidence.
README.md this file
analysis/CVE-2026-112611_type5_shading.md full site-1 writeup (both-side disasm receipts)
analysis/CVE-2026-112610_cmap_recursion.md full site-2 writeup + reachability analysis
analysis/on-device-proof.md the device run: receipts, fingerprint decode, verdicts
analysis/methodology.md the fix-diff method, reusable
poc/make_poc_shading.py generator: builds the shading oracle + control PDFs
poc/make_poc_cmap.py generator: builds the CMap oracle + control PDFs
tools/ips_parse.py generic Apple .ips crash-report parser
No crafted PDFs are committed. Generate them locally (needs nothing but Python 3):
python3 poc/make_poc_shading.py # -> poc/crash_shading_type5.pdf + poc/control_shading_type5.pdf
python3 poc/make_poc_cmap.py # -> poc/oracle_cmap*.pdf + poc/control_cmap.pdf
The shading oracle is a 7-object PDF (~2 KB) whose only unusual content is:
/ShadingType 5 dictionary with /ColorSpace /DeviceGray (nc = 1) and/FunctionType 2 function whose /Range declares 136 output dimensions instead of 1,/C0 and /C1 all 1.0 — so every out-of-bounds double written is
0x3FF0000000000000, and any wild pointer built from those spill slots dereferences a
recognizable, chosen address.The page content stream is a single operator: /Sh1 sh.
| Build | Preview the crash PDF | Expected receipt |
|---|---|---|
| iOS 27.0 / 27.0.x (≤ 24A446, pre-fix) | crashes the preview/render process | EXC_BAD_ACCESS KERN_INVALID_ADDRESS at 0x3ff000000000001c (deterministic; see analysis/on-device-proof.md) |
| iOS 27.2 (24B115, fixed) | renders cleanly | unified log: CG-SEC-187882049: invalid function for type 5 shading (range dimension does not match color space). |
To check the fixed-side log line on a 27.2 device:
log show --last 15m --predicate 'processImagePath CONTAINS[c] "quicklook" OR processImagePath CONTAINS[c] "preview"' --info --debug | grep CG-SEC
Crash reports (.ips) can be inspected with tools/ips_parse.py; on the pre-fix build the
faulting frame symbolicates to cg_shading_type5_draw, called from op_sh →
CGPDFScannerScan → the page-background render path.
The full method is in analysis/methodology.md. In short:
CoreGraphics) from both builds' dyld shared caches
(ipsw dyld extract).CG-SEC-187882049 / CG-SEC-187882136 strings localize both fixes immediately.PROVEN vs SHAPE-MATCHED.CoreGraphics iOS 27.0 (24A435, LC_SOURCE_VERSION 2050.0) vs iOS 27.2 RC (24B115, LC_SOURCE_VERSION 2050.1.6)