Add serde/serde_json for structured parsing of the export database,
replacing the hand-rolled markdown table parser with type-safe JSON
deserialization.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- resolve_imports() rewrites PE import records in-place:
- Variable slots: 0xD000BEEF | (ordinal & 0xFFF) << 16
- Thunk stubs: li r3, 0 / li r4, <ordinal> / mtspr CTR, r11 / bctr
- New -r/--resolve-imports flag on the extract command
- Without the flag, extraction is unchanged (byte-for-byte identical)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- New src/exports.rs: embeds doc/xbox360_exports.md via include_str!
and lazily parses it into a lookup table (OnceLock). Covers 2,913
exports across xboxkrnl.exe, xam.xex, and xbdm.xex.
- New src/imports.rs: decodes import records from extracted PE images
by reading the u32 at each import address, extracting record type
(variable/thunk) and ordinal, and resolving against the export DB.
- inspect command now shows a full resolved imports table with names.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Implement full decrypt + decompress pipeline for XEX2 PE extraction:
- decompress.rs: None, Basic (zero-fill), and Normal (LZX) decompression
- extract.rs: orchestrates decryption then decompression
- Wire up CLI extract command to write PE files
- LZX decompression via lzxd crate with per-frame chunk processing
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add session key derivation and payload decryption using AES-128-CBC
with well-known XEX2 master keys. Refactor CLI to use clap with
inspect/extract subcommands. Extend FileFormatInfo to parse
compression metadata (basic blocks, LZX window size/block chain).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Implement security info parsing including RSA signature, encrypted AES
key, image/region/media flags, load address, SHA-1 digests, and page
descriptors with section type classification. Add comprehensive unit
and integration tests.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Implement parsing for all 15 optional header types found in XEX2 files:
inline values (entry point, base address, stack size, system flags),
fixed-size structures (execution info, file format, TLS, game ratings,
LAN key, checksum/timestamp), and variable-size structures (static
libraries, import libraries, resource info, original PE name, Xbox 360
logo). Add comprehensive unit and integration tests.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Scaffold xex2tractor Rust project with cargo, add MIT license, README,
and XEX2 file format documentation.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>