
An extensible, deterministic static‑analysis engine that extracts high‑signal IOCs from PE binaries and text, built for SOC automation and modern threat‑analysis pipelines.
Static IOC extraction from a PE file using the IOCX CLI
This is the original IOCX engine for deterministic static IOC extraction and PE analysis. Any other repositories using the name "iocx" are not affiliated with this project.
Official links:
Modern malware is adversarial by default — malformed, evasive, and engineered to break naive extractors.
IOCX is built for environments where correctness and determinism actually matter.
IOCX is the official static IOC extraction engine — a deterministic, binary‑aware system built for DFIR, SOC automation, CI/CD security, and large‑scale threat‑intel pipelines.
Unlike regex‑only extractors or sandbox‑dependent tools, IOCX performs:
It is a core component of the MalX Labs ecosystem for scalable, modern threat analysis.
echo "http://malicious.example" | iocx -
Or scan a PE file safely:
iocx suspicious.exe -a deep
Security teams face three persistent problems:
IOCX solves this with a deterministic, static‑only engine designed for automation, safety, and scale.
IOCX is intentionally not:
It never executes untrusted code. It never performs dynamic analysis. It is static‑only by design — for safety, determinism, and CI/CD compatibility.
IOCX is engineered for the realities of modern malware, not the assumptions of legacy tools.
Stable, reproducible output — no randomness, no volatility.
Execution is unsafe. Static analysis is predictable, scalable, and CI‑friendly.
Malformed PEs, corrupted RVAs, hostile strings — IOCX treats them as normal input.
Downstream systems should never break on upgrade.
150–300 MB/s on raw text. 6–15 MB/s on typical PEs. Predictable even under worst‑case adversarial load.
These commitments are derived from a published research methodology for PE structural analysis — deterministic fixture construction, single-anomaly discipline, and Windows loader behaviour as the correctness oracle. See docs/methodology.md for the full methodology, and paax.dev for the broader adversarial-PE taxonomy and commercial fixture suite.
In short: IOCX is built for real adversarial reality, not idealized input.
150–300 MB/s sustained throughput Fast path — no PE parsing.
| Detector |
|---|
dumpbin on real binariespython-magic dependency, which caused import failures on Windows systemspip install iocx
iocx suspicious.exe
echo "Visit http://bad.example.com" | iocx -
iocx suspicious.exe -a
from iocx.engine import Engine
engine = Engine()
results = engine.extract("suspicious.exe")
print(results)
IOCX produces structured, deterministic JSON that includes IOCs, PE metadata, section analysis, heuristics, and obfuscation indicators.
The example below is an abridged output from a real adversarial PE sample. It demonstrates the shape and depth of the schema while keeping the size manageable for documentation purposes.
{
"file": "heuristic_rich.full.exe",
"type": "PE",
"iocs": {
"urls": ["http://not-a-real-domain.test/payload"],
"domains": ["example-malware.com"],
"ips": ["192.0.2.123"],
"hashes": [
"abcd1234ef567890abcd1234ef567890",
"1234567890",
"3333333333333333"
],
"filepaths": [
"/usr/src/mingw-w64-11.0.1-3build1/mingw-w64-crt/crt/crtexe.c",
"/usr/x86_64-w64-mingw32/include",
"/usr/src/mingw-w64-11.0.1-3build1/mingw-w64-crt/crt/pseudo-reloc.c"
]
},
"metadata": {
"file_type": "PE",
"imports": ["KERNEL32.dll", "msvcrt.dll", "USER32.dll"],
"sections": [
".text", ".data", ".rwx", ".rdata",
"UPX0", ".pdata", ".xdata", ".tls"
],
"resources": [],
"resource_strings": [],
"delayed_imports": [],
"bound_imports": [],
"exports": [],
"signatures": [],
"has_signature": false,
"tls": {
"start_address": 5368758272,
"end_address": 5368758280,
"callbacks": 5368754232
},
"header": {
"entry_point": 5088,
"image_base": 5368709120,
"machine": "AMD64",
"subsystem": "Windows GUI"
},
"optional_header": {
"section_alignment": 4096,
"file_alignment": 512,
"size_of_image": 155648
}
},
"analysis": {
"sections": [
{ "name": ".text", "entropy": 5.92 },
{ "name": ".rwx", "entropy": 0 },
{ "name": "UPX0", "entropy": 0.34 },
{ "name": ".rdata", "entropy": 4.03 }
],
"obfuscation": [
{
"value": "abnormal_section_layout_virtual_only",
"category": "obfuscation_hint",
"metadata": {
"section": ".bss",
"raw_size": 0,
"virtual_size": 384
}
}
],
"extended": [
{
"value": "summary",
"category": "pe_metadata",
"metadata": {
"dll_count": 3,
"import_count": 45,
"resource_count": 0,
"has_tls": true,
"has_signature": false
}
}
],
"heuristics": [
{
"value": "packer_suspected",
"metadata": {
"reason": "packer_section_name",
"section": "UPX0"
}
},
{
"value": "anti_debug_heuristic",
"metadata": {
"reason": "anti_debug_api_import",
"dll": "kernel32.dll",
"function": "CheckRemoteDebuggerPresent"
}
},
{
"value": "anti_debug_heuristic",
"metadata": {
"reason": "timing_api_import",
"dll": "kernel32.dll",
"function": "GetTickCount"
}
},
{
"value": "pe_structure_anomaly",
"metadata": {
"reason": "section_overlaps_headers",
"section": ".bss",
"raw_address": 0,
"size_of_headers": 1536
}
},
{
"value": "pe_structure_anomaly",
"metadata": {
"reason": "data_directory_overlap",
"directory_a": "IMAGE_DIRECTORY_ENTRY_IMPORT",
"directory_b": "IMAGE_DIRECTORY_ENTRY_IAT"
}
}
]
}
}
iocx/
├── examples/
├── docs/
├── tests/
└── iocx
├── detectors/
├── parsers/
├── plugins/
├── cli/
└── analysis/
IOCX is designed to be extended safely and predictably. Plugins are first‑class citizens, validated by the same deterministic snapshot tests as the core engine.
You can build:
See:
docs/specs/overlap-suppression.mddocs/specs/plugin-authoring-guidelines.mdIOCX is more than a single binary — it’s a modular ecosystem:
IOCX is used across:
Anywhere indicators need to be extracted safely, deterministically, and at scale, IOCX fits.
All test samples are:
IOCX enforces strict performance thresholds in CI to ensure:
See:
docs/performance.mdThe name IOCX refers exclusively to the official engine published on:
iocxiocx-<plugin>iocx-extension-<name>iocx-detector-<feature>IOCX development focuses on stability, extensibility, and deeper static‑analysis coverage. The items below represent ongoing areas of work and exploration.
We welcome:
See CONTRIBUTING.md for guidelines.
If you discover a security issue, do not open a GitHub issue.
Follow the instructions in SECURITY.md.
MPL‑2.0 License — see LICENSE.
| Capability | IOCX | Typical IOC Extractors | Sandbox / Dynamic Tools |
|---|
| Safety | Zero‑execution, static‑only | Regex‑only, no binary safety | Executes untrusted code (high‑risk) |
| Determinism | Fully deterministic output | Non‑deterministic under noise | Non‑deterministic by design |
| Binary Awareness | Full PE parsing, heuristics | No binary support | Yes, but unsafe + slow |
| Adversarial Resilience | Tested against malformed PEs, hostile strings | Easily bypassed | Often crashes or misclassifies |
| Performance | 150–300 MB/s (text), 6–15 MB/s (PE) | Highly variable | Extremely slow |
| CI/CD Friendly | Yes — safe, deterministic, fast | Partial | No — unsafe for pipelines |
| Schema Stability | Guaranteed | Rare | None |
| 1 MB Time |
|---|
| Throughput |
|---|
| Crypto | 0.0037 s | ~270 MB/s |
| Filepaths | 0.0041 s | ~250 MB/s |
| IP | 0.0065 s | ~156 MB/s |
| Domains | 0.0035 s | ~300 MB/s |
--min-length consistency fix is planned for v0.7.5idna dependency