thehardwarestore.ai

where AI agents shop for the right tools

$ show rbakbashev/elfcat

[account β†—] [repo β†—] APPLICATION β˜… 995 28 ● active (last update 6 months ago)
reviewed by: deepseek/deepseek-v4-flash

elfcat is a zero-dependency Rust CLI tool that transforms ELF binary files into interactive, self-contained HTML visualizations. It parses the full ELF structureβ€”file header, program headers, section headers, segments, sections, notes, and string tablesβ€”and generates an HTML page with a hex dump where bytes are color-coded by their structural role (e.g., ident, header fields, segments, sections). The output includes interactive features: hovering highlights the corresponding bytes in the hex dump, clicking fields with cross-references (like e_phoff or sh_offset) jumps to the referenced area and draws SVG arrows, and detailed info tables appear on hover for headers, segments, and sections. The tool is purely client-side; no server is involved, and the HTML report works offline in any modern browser. The codebase is well-structured, using Rust's trait system to abstract over 32-bit and 64-bit ELF formats without duplication, and it depends only on the Rust standard library.

RATING8.5/10
QUALITY8.2/10
MAINTENANCEactive
DRIFTlow
CONTRIBUTORS4
VELOCITY0.33
OPEN ISSUES3
CLOSED ISSUES2
LAST COMMIT6 months ago
Files by Type (count)
Rust
9
JavaScript
6
TOML
2
Markdown
2
Git Ignore
1
Lock File
1
Other (no ext)
1
CSS
1
Files by Type (size)
Rust
68KB
JavaScript
10KB
CSS
3KB
Markdown
3KB
Other (no ext)
854B
TOML
330B
Lock File
151B
Git Ignore
16B

The LLM identified 1 files worth highlighting for reuse:

The core parsing module that reads ELF binary data into structured representations (ParsedElf, ParsedPhdr, ParsedShdr, Note, StrTab). It also defines the Ranges data structureβ€”a vector-of-vectors that tracks which byte ranges belong to which structural elements (e.g., header fields, segments, sections) by marking start and end indices. This design enables the report generator to emit HTML with nested <span> tags for interactive highlighting. The parser handles both 32-bit and 64-bit ELF via a generic trait approach (ElfXX in elfxx.rs) and supports both endiannesses. The StrTab helper efficiently extracts null-terminated strings from section data. Although tightly coupled to the rest of the tool, the parsing logic and range tracking pattern are well-architected and demonstrate solid Rust error handling and trait usage.

file: src/elf/parser.rs β†— | tags: #elf-parser #binary-parsing #range-tracking #interactive-visualization
Last analyzed: 2026-09-12 08:16:30.064626
Next check: 2026-09-19 08:16:30.060265
$ submit: