REI Native Binaries
When to Use
- Inspect authorized PE, ELF, Mach-O, COFF and native dynamic libraries. Use for x86/x64/ARM symbol and import analysis, function-call tracing, compiler artifact identification, Ghidra/radare2/IDA evidence, decompilation comparisons, patch impact and ABI compatibility reconstruction. Ground interpretations in addresses, sections, hashes and tool versions instead of assuming pseudocode equals source.
- When performing authorized, evidence-led reverse engineering with SHA-256 artifact tracking.
Entry contract
Use only the target the user provides or explicitly authorizes. Establish the question, artifact SHA-256, permitted scope, desired output and actually available tools. If repository source is complete, inspect it first instead of treating every task as binary RE.
Available tooling
Preferred: readelf, objdump, llvm-readobj, Ghidra, radare2, Rizin, Cutter, x64dbg, LLDB. First run rei-rea inspect PATH, rei-rea deep PATH (PE/ELF only) and rei-rea plan PATH; rei-rea run readelf PATH --allow-external is opt-in only.
Procedure
- Verify PE/ELF/Mach-O header, architecture, ABI and artifact hash.
- Inventory sections, entry points, imports and resources before interpreting code.
- Trace a single feature through callers, xrefs and data transforms; capture addresses and confidence.
- Cross-check pseudocode against assembly, calling conventions and independent probes.
- For a rebuild, specify inputs/outputs and test a fixed corpus under a controlled environment.
Evidence and limits
Do not treat compiler-generated code as original source; do not execute a suspicious binary merely to obtain faster results.
For every conclusion record: target hash, source address/offset/file line, method and version, status (observed/inferred/unknown), coverage, alternative hypotheses, next verification. Do not invent installed tools or report target execution that did not happen.
See workflow checkpoints for outputs and acceptance criteria.
🏰 Rei Skills — Curated by Rootcastle Engineering & Innovation | Batuhan Ayrıbaş
Engineering Beyond Boundaries | admin@rootcastle.com
1---2name: rei-native-binaries3description: "Inspect authorized PE, ELF, Mach-O, and native libraries for symbols, imports, ABI boundaries, and call graphs."4risk: safe5source: rootcastle-rei6category: reverse-engineering7metadata:8 source: https://skillmd.com/skills/rootcastleco/rei-native-binaries9 tags: "reverse-engineering, native-binaries, pe, elf, mach-o, abi, rei-rea"10 upstream_repo: "https://github.com/rootcastleco/Rei-Reverse-engineer"11 curated_by: "rootcastle-rei"12---1314# REI Native Binaries1516## When to Use1718- Inspect authorized PE, ELF, Mach-O, COFF and native dynamic libraries. Use for x86/x64/ARM symbol and import analysis, function-call tracing, compiler artifact identification, Ghidra/radare2/IDA evidence, decompilation comparisons, patch impact and ABI compatibility reconstruction. Ground interpretations in addresses, sections, hashes and tool versions instead of assuming pseudocode equals source.19- When performing authorized, evidence-led reverse engineering with SHA-256 artifact tracking.202122## Entry contract2324Use only the target the user provides or explicitly authorizes. Establish the question, artifact SHA-256, permitted scope, desired output and actually available tools. If repository source is complete, inspect it first instead of treating every task as binary RE.2526## Available tooling2728Preferred: `readelf`, `objdump`, `llvm-readobj`, `Ghidra`, `radare2`, `Rizin`, `Cutter`, `x64dbg`, `LLDB`. First run `rei-rea inspect PATH`, `rei-rea deep PATH` (PE/ELF only) and `rei-rea plan PATH`; `rei-rea run readelf PATH --allow-external` is opt-in only.2930## Procedure31321. Verify PE/ELF/Mach-O header, architecture, ABI and artifact hash.332. Inventory sections, entry points, imports and resources before interpreting code.343. Trace a single feature through callers, xrefs and data transforms; capture addresses and confidence.354. Cross-check pseudocode against assembly, calling conventions and independent probes.365. For a rebuild, specify inputs/outputs and test a fixed corpus under a controlled environment.3738## Evidence and limits3940Do not treat compiler-generated code as original source; do not execute a suspicious binary merely to obtain faster results.4142For every conclusion record: target hash, source address/offset/file line, method and version, status (`observed`/`inferred`/`unknown`), coverage, alternative hypotheses, next verification. Do not invent installed tools or report target execution that did not happen.4344See [workflow checkpoints](references/workflow.md) for outputs and acceptance criteria.4546---4748> 🏰 **Rei Skills** — Curated by [Rootcastle Engineering & Innovation](https://www.rootcastle.com) | Batuhan Ayrıbaş 49> Engineering Beyond Boundaries | admin@rootcastle.com