libschnauzer
Schnauzer is both library and tool for parsing mach-o files
Features
- Zero copy. Does not loads whole binary into memory. Uses iterators to list potentially large amount of items
- Endian aware
- Implements derive macro for automatic field enumeration, that, for example, very convenient for printing arbitary load commands. There even no need to write large
matchblocks for any type of load command - Prints file structure in color for better user experience
Installation
cargo install schnauzer
Supported commands
# Prints almost all binary info
schnauzer path_to_binary
# Prints symtab
schnauzer syms path_to_binary
# Prints relative paths
schnauzer rpaths path_to_binary
# Prints used dynamic libraries
schnauzer dylibs path_to_binary
Example output
Put something like in your console:
schnauzer /bin/cat
And you get:

Some info may be too big to be printed with other info that may be inconvenient. So there separate subcommand to print all nlists:
schnauzer syms /bin/cat

Documentation
docs.rs/schnauzer/0.2.0
Usage
[]
= "0.2.0"
Examples
Simple debug print
use ObjectType;
use Parser;
use Path;
Using AutoEnumFields derive (code taken from src/main.rs)
let h = macho.header;
for field in h.all_fields
Contacts
You may email me: arsynthdev@gmail.com