r/ExploitDev • u/iocx_dev • Jun 11 '26
99 adversarial PE files: exploring malformed‑binary behaviour across major analysis tools
I’ve built a 99‑fixture adversarial PE corpus to explore how different tools behave when confronted with deliberately malformed but still loadable binaries.
Each fixture introduces one corruption pattern - no packers or multi‑anomaly noise, which allows for clean attribution of behaviour. The anomalies span:
entrypoint redirection
overlapping/invalid sections
header inconsistencies
directory OOB conditions
TLS edge cases
recursive/malformed resources
Authenticode structural corruption
entropy‑field manipulation
I tested 6 tools commonly used in exploit dev workflows:
IOCX
Ghidra
Detect It Easy
radare2
PEview
CFF Explorer
Behavioural patterns with exploit‑relevant implications:
Literal parsers (r2, PEview) stable, byte‑accurate, but provide no anomaly visibility
Semantic parsers (CFF) adjust malformed fields, masking exploit‑useful inconsistencies
Heuristic tools (DIE) ignore structure, blind to malformed metadata
Reconstructive loaders (Ghidra) build internal models, may omit conflicting metadata, and can crash on extreme entropy fixtures
Hybrid literal‑semantic tools (IOCX) preserve raw bytes and surface anomalies explicitly
For exploit dev, malformed PE structures can act as:
parser differentials
crash primitives
metadata confusion vectors
loader‑model inconsistencies
analysis‑evasion surfaces
This corpus maps those behaviours systematically.
Full write‑up (Part 1):
The Adversarial PE Analysis Series — Why PE Parsers Break
Corpus and fixture spec: https://github.com/iocx-dev/iocx
(fixtures are under /tests/contract/fixtures/layer3_adversarial)
1
u/Moist_Theme3682 Jun 12 '26
very impressive! It reminds me the experience when I was a support engineer and using windbg and winhex to do some manual analysis.