# One stale IPC index, two kernel outcomes on iOS 27.1

*Lab notes from October 29, 2026 · Tested on one iPhone19,4 running iOS 27.1 build `24A94425`*

One small number sent us down two very different paths. In one test, the iPhone rebooted at a memory-tag fault in the request-table access path. In a second, carefully bounded test, the phone stayed up while a **different live request** changed state. That second result gave us a way to see the indexing mistake without relying on a crash.

These are real observations on one build. They are **not** arbitrary kernel read/write, a sandbox escape, or a jailbreak. The successful state change was observed once, so this post does not claim a reliability rate.

![Flow diagram: a freed Mach name turns its old request-index field into a free-list link; iOS 27.1 reuses that number, leading either to wrong-request arming or an invalid load.](assets/stale-index-two-outcomes.svg)

## The bug, without the alphabet soup

Mach ports let an app send messages and ask to be notified when a full queue can accept another one. The kernel keeps the app's *port names* in one table and pending *notification requests* in another. A name entry has a field that can hold a request index while the name is live. When the entry is freed, that same field becomes a link in the name table's free list.

The interesting sequence is:

1. The app has a normal send right with a delayed send-possible notification.
2. A final `MOVE_SEND` consumes that right. Its IPC name entry is freed, and the entry's field is overwritten with the **name table's free-list head**.
3. On this 27.1 build, the message-header path reads that field *after* the move and uses it as an index into the **port's request table** when `MACH_SEND_NOTIFY` is set.

Those are different tables. If the free-list number names another live request slot, the kernel can arm the wrong request. If it points beyond the request allocation, the old helper attempts an out-of-bounds load. The exact 27.1 disassembly shows a load at `request_table + 16 × index`, a test of bit 1, and a conditional OR of bit 0 into the same word. The successful run was **not traced at that store instruction**; the mechanism is inferred from those instructions and the uniquely mapped state change below. Apple's published [IPC entry layout](https://github.com/apple-oss-distributions/xnu/blob/f6217f891ac0bb64f3d375211650a4c1ff8ca1ea/osfmk/ipc/ipc_entry.h#L103-L124), [space-info readback](https://github.com/apple-oss-distributions/xnu/blob/f6217f891ac0bb64f3d375211650a4c1ff8ca1ea/osfmk/ipc/mach_debug.c#L215-L264), and [header-copyin path](https://github.com/apple-oss-distributions/xnu/blob/f6217f891ac0bb64f3d375211650a4c1ff8ca1ea/osfmk/ipc/ipc_kmsg.c#L2140-L2162) help explain the behavior; our address-level claim comes from the extracted **exact-build** binaries, not an assumption that current open-source XNU is byte-identical.

## The clean run: one wrong request changed

The reviewed test app created ordinary ports and 510 distinct delayed send-once notification requests. It stopped only when the port's request table was larger than the app's IPC name table and a held dummy name's index matched exactly one *other* live delayed request. It filled the target queue, moved the receive right into a carrier, checked that one normal send right remained, saved a marker that the host copied to the Mac, and waited for one host signal.

The copied pre-send marker gave these values on our phone:

| Check | Value |
| --- | ---: |
| Request-table capacity | `768` |
| IPC name-table size | `682` |
| Usable free name entries after receiver move | `39` |
| Held dummy index | `113` |
| Different delayed request mapped to slot 113 | name `57863`, registration `108` |
| Target queue before receiver move | `1 / 1` full |
| Normal send rights left in the app | `1` |

After one `SIGUSR1`, the app checked that the IPC name table was still smaller than the *pre-move* request capacity and rescanned the live request states; the fresh check found **61** usable free name entries. It released the dummy name and read the free-list head as **113**. One zero-timeout `MOVE_SEND` message with `MACH_SEND_NOTIFY` then returned `0x10000004`, which the iPhoneOS SDK calls **`MACH_SEND_TIMED_OUT`**. The message was not delivered.

Immediately afterward, all **510** send-once request names were still present and marked as send-possible requests. Before the send, **510/510** were delayed. After it, **509/510** were delayed. The only changed name was `57863`, still mapped to slot **113**: its type changed from `0xe0040000` to `0xc0040000`, clearing the SDK's `MACH_PORT_TYPE_SPREQUEST_DELAYED` bit (`0x20000000`). The other 509 stayed delayed. The phone remained wired and booted; the system crash-log count stayed **136 → 136**.

That is strong evidence of **in-bounds wrong-request arming**: a confined kernel state change to an existing request record, selected by the stale free-list number. It is not an arbitrary-address or arbitrary-value write. The copied pre-send and result JSON have SHA-256 values `db43c2b87778227454550e1383fbc9549d5ec7b27b417069063e99f224c7e65c` and `4786443848a3bed3c6895224dbc2bad051dc975261183a44b9eed063462387ed`, respectively.

## The earlier reboot: an invalid load stopped by memory tagging

A separate one-shot app hit the same old request-mark path with index **116**. Its preserved kernel panic identifies the faulting instruction as the unchecked load at unslid `0xfffffe000aba75f0`, with an address `0x740` bytes from the request-table base (`116 × 16`). The memory tag did not match, so the phone rebooted **before** the conditional store. Exact-build disassembly and the fault offset point to an out-of-bounds read attempt, but the pre-send table-capacity marker was lost in the reboot; that capacity is **not directly recorded for this run**. We did not get an unknown kernel value back, and we did not observe an out-of-bounds write. The crash harness is preserved in the private research archive but is not part of this public reproduction bundle. The saved panic's SHA-256 is `675093360a6535f32cef8e9b21e3fd685e3fbe3e895d9c22e699de1a7f8e0b27`.

## A second, separate Bluetooth parser observation

We also triggered a **different** kernel panic once using a locally advertised, paired Bluetooth HID accessory. A 512-byte Report Map with one missing local Usage in its second Collection led IOHIDFamily to attempt a four-byte read starting at offset **516** from a **512-byte** parser allocation. Memory tagging stopped it. A valid 512-byte map with the required Usage did not panic and exposed the expected usage pairs. The maps differed only at offsets 37–38: `09 7F` in the valid control versus `75 08` in the missing-Usage test. Their SHA-256 values were `e75856439b71f84d5d6b1a7e613d265ef1b675d80fc85d509a9cf9869c1386a9` and `cd9f7cd9dcc584d34e926713145d659fac8da4270a851161e40e81515b39b285`; the panic report's SHA-256 was `30288899cfda3fcd59c1889ddb592cb53b1d33a02b3c581d4b37d54a9f736cf8`. This was a deliberate local/paired test, **not** an unpaired or zero-click attack. It produced no leaked value or write primitive. Apple's published [HID Collection Usage code](https://github.com/apple-oss-distributions/IOHIDFamily/blob/777ccd9698845aadf711e32d843c8c9b777431d9/IOHIDSystem/IOHIDDescriptorParser/HIDGetCollectionNodes.c#L176-L195) is a useful structural comparison, but our fault location comes from the exact-build panic and binary.

## Reproducing the bounded IPC observation

The [source-only Xcode project](assets/MachIPCInBoundsLogicProbe-source.zip) contains the reviewed one-shot logic and a detailed host procedure in its README. It contains **no signed app or personal provisioning profile**. The ZIP's SHA-256 is `98fb392b3cd645e1de47c8d871a207340cbea3560dd250d61abf5a9d21202b8f`; the source's `main.m` SHA-256 is `84fc580b69ee1626f13c5916b63e9fc26f5abc271e1fc2a18240eb4fd54e95c3`. Set your own signing team and unique bundle identifier before building. The app deliberately refuses devices other than `iPhone19,4` on exact build `24A94425`; changing that guard would be a new experiment, not a reproduction of this one.

The short version:

1. Use a restorable lab phone on the exact model/build, Xcode with the iPhoneOS SDK, your own signing identity, and USB/CoreDevice access. Record the build and crash-log inventory first.
2. Build the source project, install it **once**, and launch it through CoreDevice with `--run-reviewed-once`. A normal icon tap does nothing.
3. Copy `mach-ipc-inbounds-logic-stage1.json` from the app container to the Mac. Confirm its exact device/build, full queue, last send-only right, `request_capacity > ipc_space_size`, at least 32 usable free name entries, and the app-reported matched name and delayed type at the held dummy index. The reviewed app checks the full slot map internally; the stage marker contains its summary, **not the full map**. **If any check fails, do not signal the app.** Numeric names and the stop count may differ from our run.
4. If every gate passes, signal the saved app PID **once** with `SIGUSR1`. The app performs fresh checks, releases the dummy, checks the head again, sends at most one zero-timeout message, and saves `mach-ipc-inbounds-logic-result.json`.
5. Compare the raw before/after request counts, mapped name, slot, type bits, send return, and crash inventory. A status string by itself is not evidence. Do not loop or rerun the app to chase a result.

The last head snapshot cannot lock the IPC namespace until the kernel processes the send. A concurrent name-table growth could still make the final access out of bounds and reboot the phone. The single clean run is an observation, **not** a guarantee that the procedure is panic-free on other devices or attempts.

## What this means for exploitation and attribution

The clean test confirms a narrow wrong-record state change; the panic confirms an invalid read *attempt*, with its out-of-bounds cause inferred from exact-build code and the fault offset. Neither gives unknown-byte disclosure, arbitrary kernel read/write, code execution, privilege gain, persistence, or a jailbreak. A useful exploit would need an additional primitive or a concrete privileged consequence that we have not found.

The exact iOS **27.2** binaries change this IPC path: they save and clear the request index across the final right move and check the request-table extent before the load. We also found the same two repairs in an independently extracted iPadOS **26.7.2** kernel pair. [Apple's iOS 27.2 advisory](https://support.apple.com/en-us/149230) and [iOS 26.7.2 advisory](https://support.apple.com/en-us/149227) list relevant kernel out-of-bounds classes, but neither names this function. **We are not assigning a CVE.** The exact patch strongly suggests Apple already knew the underlying bug. This post documents our own device observations; it does not claim first discovery.

*The one-shot app, its stage and result receipts, and the independent reviews remain preserved in the local research archive. The public download contains only sanitized source. No signed binary, raw panic report, device ID, or development-team credential is included.*


## October 30 update: AppleAVE2 panic reproduced on the Duo

On October 30, 2026, we independently reproduced the publicly reported AppleAVE2 `NumberOfTemporalLayers=16463` kernel panic on an iPhone Duo (`iPhone19,4`, iOS 27.1 build `24A94425`). One independently reviewed, exact-build-gated diagnostic app was launched once. No repeat or larger value was run. This is **device-specific reproduction and fault analysis**, not first discovery or a working exploit; one run does not establish a reliability rate.

Credit goes to the [public CVE-2026-112705 reproduction by MchinaMd57764](https://github.com/MchinaMd57764/AVETemporalPoC-CVE-2026-112705), which attributes the original discovery to **Calif / Chollima**. Its older-device fault offset differs from ours; the shared register fingerprint does not make the builds interchangeable.

The preserved panic names `videocodecd` and places the fault in AppleAVE2 at **+0xD998**, with **FAR=0x59** and **x19=1**. Exact-build analysis identifies the faulting instruction as `stp x0,x0,[x0]`; its caller computed `x0=x19+0x58`. A later backtrace audit places the active request in **selector-2 Close**, during session cleanup. Teardown faults before its Close reply is written.

The panic and exact-build code strongly support a **constrained pointer-corruption path**: the temporal-layer loop reaches a pointer field, and cleanup later consumes the corrupted value. The individual fill instruction and selector-5 payload were not captured in this run, so those internal transitions remain inferred. The app-side attempt/result files were not recovered. The preserved panic provides the fault evidence; no app-side journal or successful reply is claimed.

The observed pointer word was 1. This does not establish an arbitrary-address or arbitrary-value write, a leaked kernel value, or an app-visible read/write primitive. Further work should begin with offline analysis of consumers and outputs rather than repeating the high-layer panic.

## Ongoing research: HEVC UserRPSForFaceTime parser

**Preliminary research lead — not a confirmed vulnerability.** An exact-build code audit identified a possible bounds issue in the HEVC `UserRPSForFaceTime` nested-array parser. On October 31, 2026, an ordinary signed app successfully set **one harmless record** on the same Duo: `VTSessionSetProperty` returned status 0. Both picture counts were zero, skipping the nested picture loops. No frame was submitted, no encoder preparation or driver selector was sent, and no oversized or malformed value was run. The crash-log inventory was unchanged.

This is acceptance evidence for the bounded value, not proof of every parser branch, service-memory mutation, or memory corruption. A later offline safety gate found that the proposed larger-array readback could overwrite live resource pointers that normal session invalidation and destruction consume. The proposed larger test was therefore **withheld**. The acceptance result does not convert the static bounds concern into a live-confirmed finding.

## Current conclusion and next steps

**We have demonstrated kernel panics, but no kernel read/write primitive, code execution, persistence, or jailbreak.** The IPC wrong-request state change, HID panic, AppleAVE2 reproduction, and preliminary HEVC parser lead remain distinct observations with different evidence limits.

Next steps are offline validation of the parser's allocation and cleanup boundaries, careful comparison of exact-build fixes, and mapping whether any affected state has a concrete app-visible consequence. Any future device experiment needs a separately reviewed, bounded protocol; the withheld larger HEVC test remains unexecuted. Future updates will record the date, exact build, new evidence, and changes in conclusions.

*Updated October 31, 2026. This public summary omits personal device identifiers, signing identities, raw panic reports, and raw device telemetry.*
