# CVE-2026-84607 Exploitation Strategy — DART-Aware Chain

**Device:** iPhone 17 Pro (iPhone18,1), A19/T8150, iOS 26.6.2 (23G90)  
**Status:** Kernel panic CONFIRMED. Exploitation path under development.  
**Date:** 2026-11-13

## 1. What We Know (Confirmed Facts)

### The Bug
- `vps_max_layer_id` lacks bounds checking on iOS 26.6.2
- Patch adds `vps_max_layer_id < 63` check
- `RequiredHEVCVideoParameterSetAlphaLayerID` accepts any value 0-255 via VTSessionSetProperty
- No userspace clamping — value reaches kernel unchecked
- VPS bitstream path: 6-bit field, wraps mod 64 (max useful OOB = 1 element, value 63)
- IOKit config struct path: may carry full unclamped value (NEEDS Ghidra to confirm)

### The Crash
```
panic(cpu 0): "dart-ave (0xf4fffe2409992000): DART(DART) error: SID 0
PTE invalid exception on write of DVA 0x100007d2a80
(CTE 0x10 SEG 0 PTE 0x1f4) ERROR_SID_SUMMARY 0x00003100
TIME 0xee33afe1ab7b TTE 0 AXI_ID 0xc1"
@AppleT8110DART.cpp:2369
```

**DVA Analysis:**
- `0x100007d2a80` = base `0x100000000` + offset `0x7d2a80` (~8.2MB into device VA space)
- PTE index `0x1f4` = 500 (decimal) — page 500 in segment 0
- With 16KB pages: offset = 500 * 16384 = 8,192,000 bytes ≈ 8.2MB ✓ (consistent)
- AXI_ID `0xc1` = encoder write channel (not read)
- SID 0 = primary DMA stream

**Kernel Memory Layout (from panic):**
- KernelCache base: `0xfffffe004fb10000`
- KernelCache slide: `0x0000000048b0c000`  
- Zone map: `0xfffffe110c000000 - 0xfffffe370c000000`
  - VM zone: `0xfffffe110c000000 - 0xfffffe16d8000000`
  - RO zone: `0xfffffe16d8000000 - 0xfffffe1972000000`
  - GEN0-3: `0xfffffe1972000000 - 0xfffffe30a2000000`
  - DATA: `0xfffffe30a2000000 - 0xfffffe370c000000`

### What AlphaLayerID=255 Does Alone
- Encode callback returns error `-17691` (kVTParameterErr)
- Hardware encoder **rejects** before DMA operation
- NOT the DART panic trigger by itself

## 2. Critical Insight: The DART Panic Is Not The Exploit Target

**The DART panic is a secondary crash effect.** The actual vulnerability is in kernel memory:

1. AlphaLayerID value flows from userspace → VideoToolbox → AppleAVE2 kernel driver
2. Kernel uses it as an array index WITHOUT bounds check
3. OOB write corrupts adjacent kernel data structure members
4. Corrupted member is eventually used as a DMA buffer pointer or size
5. Hardware encoder attempts DMA to the corrupted address
6. DART catches unmapped address → panic

**The exploit target is step 3** — the kernel memory corruption, not the DMA write.

### Evidence from Prior AppleAVE2 Exploits

**CVE-2019-8795/8797 (SSD Advisory):**
- Method index 7 (`_SetSessionSettings`), 0x108-byte input buffer
- `statsMapBufferArray` at offset 0x1B60 (5 entries × 0x28 bytes)
- `memoryInfoCnt2` OOB → reads past `statsMapBufferArray` into `sessionSettings_block1` (user-controlled)
- Kill chain: OOB → `DeleteMemoryInfo` → `CompleteFence` → vtable call at offset 0x28 → PC control
- **Key:** OOB into user-controlled adjacent data = controllable corruption

**CVE-2026-112705 (Calif/Chollima):**
- NumberOfTemporalLayers OOB write on iOS 27.0.1
- "Fixed-offset constant fill" — predictable write, not arbitrary
- Same `dart-ave` PTE-invalid panic signature
- DoS only (no R/W primitive from this alone)

## 3. The Two OOB Paths

### Path A: VPS Bitstream (6-bit, max OOB = 1)
- `vps_max_layer_id` in VPS NAL is 6-bit: values 0-63
- Array likely `layer_idx[63]` (indices 0-62, checked < 63)
- Value 63 → single element OOB (index 63 in 63-element array)
- Write value: likely `layer_idx[63] = 1` (layer index assignment)
- **OOB distance: exactly 1 element**
- Predictable but very constrained

### Path B: IOKit Config Struct (potentially unclamped)
- If kernel reads AlphaLayerID from IOKit config before VPS parsing
- Could receive full 0-255 range
- Array index 255 in 63-element array → OOB by 192 elements
- **Much more powerful** — corrupts arbitrary adjacent data
- **MUST CONFIRM WITH GHIDRA** — highest priority Ghidra task

### The Research Question
The kernel receives BOTH:
1. The VPS bitstream (with 6-bit wrapped value)
2. The IOKit configuration struct (with raw app-supplied value)

Which does it use for the vulnerable array access? This determines whether we have:
- A 1-element OOB (bitstream path) — requires precise adjacent-field targeting
- A 192-element OOB (config struct path) — can reach far into heap or adjacent objects

## 4. Exploitation Strategies

### Strategy A: Controlled Kernel Heap Corruption (Preferred)

**Goal:** Use OOB write to corrupt an adjacent kernel heap object, achieving a controlled primitive.

1. **Identify the target array** — Ghidra: find `layer_idx` or equivalent in AppleAVE2
2. **Map adjacent heap objects** — What kalloc zone? What objects are allocated nearby?
3. **Groom the heap** — Allocate/free objects to place a controlled victim adjacent to the OOB target
4. **Corrupt victim object** — OOB write overwrites a field in the victim:
   - Function pointer → PC control (needs PAC bypass on A19)
   - Size field → undersized buffer → heap overflow with controlled content
   - Refcount → UAF via premature free
   - Pointer → arbitrary read/write primitive

**Heap grooming for AppleAVE2:**
- Create multiple VTCompressionSessions to allocate adjacent kernel structs
- Use IOSurface objects for controlled heap content (proven technique from SSD advisory)
- The `sessionSettings_block1` pattern: user-controlled data placed in predictable kernel offset

### Strategy B: DMA Region Grooming (Advanced)

**Goal:** Make the OOB DMA write land within a mapped DART region we control.

1. Current crash: DVA `0x100007d2a80` is unmapped → DART panic
2. If we can extend the DART mapping to cover that address, the write succeeds
3. **Allocate large IOSurfaces** to expand the DART-mapped region
4. Place controlled data at the target DVA
5. After OOB write corrupts it → use the corrupted data as a primitive

**Challenges:**
- DART mappings are per-stream, controlled by kernel
- We can influence them through IOSurface allocation (size, count)
- Need to determine if DVA `0x100007d2a80` is deterministic across crashes

### Strategy C: Chain with CVE-2026-86916 (Kernel UAF)

**Goal:** Use AppleAVE2 OOB as a heap state destabilizer, then exploit the UAF.

1. AppleAVE2 OOB corrupts a reference count or allocation metadata
2. This creates a dangling pointer or double-free condition
3. CVE-2026-86916 (kernel UAF) is triggered to exploit the corrupted state
4. UAF → controlled object replacement → kernel R/W

**Advantage:** Combines two bugs for more reliable exploitation
**Risk:** Two bugs means more moving parts, harder to stabilize

### Strategy D: Repeated Single-Element OOB (If Path A only)

**Goal:** Exploit the 1-element OOB from VPS path through repeated operations.

1. Encode multiple frames with AlphaLayerID=63 (max VPS OOB)
2. Each encode cycle performs the OOB write
3. Between cycles, groom the heap to place different objects adjacent
4. Eventually corrupt a useful field

**This is similar to how NumberOfTemporalLayers was exploited in CVE-2026-112705 context.**

## 5. Immediate Next Steps (Priority Order)

### P0: Ghidra Analysis (BLOCKING)
1. Import unpatched iOS 26.6.2 kernelcache into Ghidra
2. Find AppleAVE2 kext within the kernelcache
3. Search for `AVE_HEVC_CheckVPSExtBounds` (from our diff)
4. Trace backward from there to find the array access
5. Determine: does kernel use VPS bitstream value or IOKit config value?
6. Map the struct layout — what's adjacent to the target array?

### P1: Narrow Isolation Test Completion
- Continue testing suspects 2-8 on device
- If a specific suspect triggers DART panic → we know the exact trigger
- Compare DVA addresses across panics (deterministic = groomable)

### P2: DVA Determinism Test
- If we get a second panic, compare DVA with `0x100007d2a80`
- Same DVA = deterministic target (easier to groom)
- Different DVA = address depends on heap state (harder, need info leak)

### P3: Heap Layout Reconnaissance
- Build a tool that allocates IOSurfaces of various sizes
- Monitor DART mapping changes through error codes
- Map the relationship between allocation patterns and DVA layout

## 6. PAC Considerations (A19 / arm64e)

The A19 chip has Pointer Authentication Codes (PAC). Any exploitation strategy that targets function pointers must deal with PAC:

- **PAC-A (code):** `pacia`/`autia` — protects return addresses, vtable entries
- **PAC-D (data):** `pacda`/`autda` — protects data pointers  
- **Context values:** discriminators mixed into PAC generation

**Bypass options:**
1. **Data-only attack:** Corrupt non-pointer fields (sizes, counts, flags) — no PAC
2. **Signing oracle:** Find a kernel code path that signs a controlled value
3. **PAC collision:** 2^17 chance for 17-bit PAC — may be feasible with repeated attempts
4. **SPTM writer bug:** CVE-2026-28952 pattern (integer overflow in `_zalloc_ro_mut` bounds check) — but this was patched in 26.5

**Preferred approach: data-only corruption** — modify size fields, reference counts, or configuration values rather than code pointers. This avoids PAC entirely.

## 7. MIE Considerations

Memory Integrity Enforcement (MIE) is ARM MTE-based. On iPhone 18 Pro (A19):
- Kernel heap allocations get random 4-bit tags
- Load/store checks tag matches
- Corrupting adjacent memory with wrong tag → MTE fault

**However:**
- MIE is probabilistic: 1/16 chance of tag collision per allocation
- DMA writes bypass MTE (hardware DMA doesn't check tags)
- The OOB through hardware encoder DMA may inherently bypass MIE
- MIE was announced for iPhone 18 series — confirm if enabled on 26.6.2

## 8. References

- SSD Advisory: AppleAVE2 userclient method 7 OOB (CVE-2019-8795/8797)
- Black Hat EU 2020: Story of Jailbreaking iOS 13
- KeenLab BH 2018: DART/IOMMU background
- FFmpeg VPS extension parser: reference implementation for layer-indexed arrays
- Calif blog: MIE bypass technique (CVE-2026-28952, integer overflow in `_zalloc_ro_mut`)
- ironpeak.be: MIE bypass analysis, SPTM writer gaps
- CVE-2026-112705: AppleAVE2 NumberOfTemporalLayers OOB (DoS only, fixed iOS 27.2)
