Binwalk
$ binwalk Official Med RiskBinwalk (binwalk) inspects firmware images for embedded filesystems (SquashFS, JFFS2, CramFS), compression streams, and encryption entropy (-E), and extracts discovered payloads (-e). Scan-only invocations are read-only, while -e and -M write extracted trees to disk.
brew install binwalk binwalk scans and unpacks multi-MB local firmware blobs directly on disk.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Non-interactive and predictable, though primary output is fixed-width table text (v3 added -l JSON logging, while v2 relies on text tables).
- Non-interactive flag execution
- Primary stdout is tabular text rather than universal JSON
Signature scanning is read-only, whereas recursive -e -M extraction invokes external unpackers and can trigger path-traversal or disk-bomb expansion on hostile firmware.
- Read-only default signature scan
- Extraction (
-e/-M) writes untrusted archives to disk
Installable via brew, cargo, and GitHub releases; full extraction relies on third-party tools like unsquashfs or 7z on PATH.
- Available via
brewandcargo, with external extractor dependencies
Standard first-step tool for embedded firmware triage and filesystem extraction.
- Identifies dozens of embedded compression and filesystem headers
Maintained under ReFirmLabs/binwalk (MIT license, rewritten in Rust in v3).
- Official
ReFirmLabs/binwalkrepository
Clear README and --help covering scan, entropy, and extraction options.
- Concise README and
--helpreference
Security, Auth & Guardrails
No authentication credentials used; operates solely on local firmware files.
MIT open-source CLI; free and offline.
# Binwalk (binwalk) Agent Rules - Run read-only `binwalk <file>` before extracting with `-e`. - Extract into an isolated `/tmp` directory with `-C` and avoid `-M` recursive extraction on untrusted images outside sandboxes.
Agent-Ready Command Recipes
Safe Read-Only Queries
binwalk firmware.bin
Lists embedded headers, offsets, and filesystem signatures inside firmware.bin read-only.
binwalk -E firmware.bin
Measures byte entropy across firmware.bin to spot encrypted or compressed regions.
Controlled Writes & Previews
binwalk -e -C /tmp/fw-out firmware.bin
Extracts recognized payloads (-e) into /tmp/fw-out via -C for subsequent inspection.
Strengths for Agents
- + Fast read-only header and entropy triage (
binwalk,binwalk -E) on raw firmware blobs. - + Rust v3 rewrite improves speed and eliminates legacy Python runtime fragility.
Caveats & Pitfalls
- ! CLI flags differ slightly between legacy Python v2 and Rust v3 builds in distro vs Homebrew/Cargo installs.
- ! Recursive
-e -Mextraction on untrusted firmware should be confined to isolated directories.