Files
reverse-engineering-anything/docs
Eliran Zachandmorluto 208b81d724 feat(artifacts): inspect Game Boy and GBA ROM headers (#16249)
* feat(artifacts): inspect Game Boy and GBA ROM headers

Game Boy and Game Boy Color images (game-boy-rom) are claimed when at
least the first 24 bytes of the boot logo at 0x104 match, the half every
boot ROM compares. Root metadata reports the entry code and its JP
target, full or top-half logo match, title and manufacturer code, CGB
and SGB flags, mapper and features, declared ROM and RAM sizes,
destination, licensee codes, version, and declared and computed header
and global checksums. The global checksum is summed over the file in
bounded reads.

Game Boy Advance images (gba-rom) are claimed from an ARM branch at 0,
the fixed 0x96 at 0xB2, and the boot logo or a matching complement
check. Root metadata reports the entry branch target, logo match, title,
game and maker codes, fixed value, unit and device type, version, the
complement check, and the multiboot fields when that layout could apply.

Both serve header.bin and program.bin as stored ranges. Logos are
compared by SHA-256 digest, so no logo bytes are carried. Checksum,
logo and size disagreements leave coverage unknown; a header cut short
is refused as truncated with the offset where the file ends.

* fix(artifacts): keep missing GBA multiboot fields unknown and pin checksum vectors

A GBA file that ends inside the multiboot fields reported boot_mode and
slave_id as zero. They are now null, with a limitation naming where the
file ends. The Game Boy reader charges artifact_limits.expanded_bytes
from the file size before it sums the file for the global checksum.
Checksum tests now use hand-derived vectors instead of copying the
parser's own result.

* refactor(artifacts): read Game Boy and GBA header fields through BinaryReader

The GBA parser decoded words with a local reader that read missing bytes
as zero. Both parsers now read header fields through BinaryReader, as the
tool-design guide requires, after their length checks. The fixtures write
literal offsets instead of the parsers' field constants, and the guides
say inventory reads the stored members to hash them.

* fix(artifacts): read documented GB size codes and MBC4, refuse truncated GBA headers

* style(artifacts): format the handheld ROM test

---------

Co-authored-by: morluto <76467478+morluto@users.noreply.github.com>
2026-12-04 12:08:57 -05:00
..

Documentation directory

Find an installation step, investigation guide, or contributor reference by task. The REA website has worked examples and product pages.

Getting started

Desktop applications

Agent environments

Native binaries

JavaScript and Electron

Browser and captured websites

Android applications

Apple applications

.NET assemblies

Firmware

HarmonyOS packages

Packages and metadata

WebAssembly

EVM contracts

Databases and recorded packets

Audit logs

Process capture and instrumentation

Provider setup and formats

Contracts and evidence

Development and verification

Release migrations

Signal recordings

Generated files and release records

Path Owner and update command
public/product-catalog.json Ignored contract projection; npm run docs:generate
verification/managed-conformance-*.json Ignored managed conformance projections; npm run evidence:generate
error-contract.schema.json Tracked schema from contracts; npm run docs:error-schema
user-visible-errors.csv Generated error code and category per domain and provider-owned error case; npm run docs:error-schema
releases/<version>.contributions.json Durable release contribution record; follow the release guide

Regenerate catalogs and Evidence projections from their canonical source. Release records preserve the exact commit messages and references for each release. Guides share authored images in assets/.