RABIN2(1)
π¦ rabin2 β section 1 of the manual, bestie π¦
okay so this is rabin2 (that's the name, and it lives in manual section 1), and she is literally the Binary Information Extractor. think of her as the friend who can look at any binary and tell you what's inside it. no cap. π
β¨ NAME β¨
rabin2 β Binary Information Extractor
π SYNOPSIS π
rabin2 [-AcdeEghHiIjJlLMpqQrRsStuVvwxZ] [-a arch] [-b bits] [-B addr]
[-C fmt:C:[D]] [-D lang sym|-] [-f subbin] [-F binfmt] [-k query]
[-K algo] [-m addr] [-n str] [-N minlen:maxlen] [-o str]
[-O binop] [-X fmt file ...] [-@ addr] file
πΈ DESCRIPTION πΈ
she's a binary information extractor, and she speaks ELF, PE, MZ and Mach-O β giving you all the tea on headers, sections, symbols, imports, exports and debug data. it's giving forensic main character energy. π₯
also, most of these options are lowkey available inside the radare2 i command too (just type i? for help). iykyk. π
π OPTIONS π
-@ addrβ show the section, symbol or import that lives at that given address-Aβ list sub-binaries and their associated arch-bits pairs-a archβ set the arch (x86,arm, .. or<arch>_<bits>)-b bitsβ set the bits (32,64, ...)-B addrβ override the base address (for address independent binaries)-cβ list classes-ccβ list classes in header format-C [fmt:C[:D]]β create[elf,mach0,pe]with Code and Data hexpairs (see-a)-dβ show debug/dwarf information-D lang symbolname|-β demangle a symbol name (or-to read from stdin) for that lang β options arecxx,ibmxl,swift,java,msvc, ..-eβ program entrypoint-eeβ constructor/destructor entrypoints-Eβ globally exportable symbols-f subbinβ select the sub-binary architecture. super useful for fat-mach0 binaries π«Ά-F binfmtβ force it to use that bin plugin (ignore header check)-gβ same as-SMZIHVResizcld -SS -SSS -ee(show all info). the "give me everything" option, obsessed.-G addrβ load address . address to header-hβ show this help message-Hβ header fields-Iβ binary info-iβ imports (symbols imported from libraries)-jβ output in json-J varβ display an environment variable-k queryβ perform an SDB query on the loaded file. for example:'*'-K algoβ calculate section checksums (md5,sha1, ..)-lβ list linked libraries to the binary-L pluginβ list supported bin plugins or plugin details-m addrβ show the source line ataddr-Mβ main (show address of main symbol)-n strβ show the section, symbol or import namedstr-N minlen:maxlenβ force min:max number of chars per string (see-zand-zz)-o strβ output file or extraction directory for write operations-O binopβ perform a binary operation on the target binary (dump, resize, change sections, ...). use-O helpfor more info:
e/0x8048000 change entrypoint
d/s/1024 dump symbols
d/S/.text dump section
r/.data/1024 resize section
R remove RPATH
a/l/libfoo.dylib add library
p/.data/rwx change section permissions
c show Codesign data
C show LDID entitlements
-pβ show always physical addresses-Pβ show debug/pdb information-PPβ download the pdb file for the binary-qβ be quiet, just show less data-qqβ show less info (no addr/size for-zfor ex.)-Qβ show load address used bydlopen(non-aslr libs)-rβ radare output-Rβ relocations-sβ symbols-Sβ sections-SSβ segments-SSSβ sections mapping to segments-tβ display file hashes-Tβ display file signature, certificates and signing details-uβ resources-vβ display version and quit-Vβ show binary version information-wβ display try/catch blocks-xβ extract sub-binaries contained in the file (for example, architectures inside a FAT Mach-O binary). combine it with-S,-SS, or-uto extract sections, segments, or raw resources instead. so like,-xSextracts sections,-xSSextracts segments, and-xuextracts resources. resource extraction may be combined with section or segment extraction. section, segment and resource filenames include their kind, sanitized name or type, and index β and existing files are never overwritten, no worries bestie π«Ά. use-o dirto pick the output directory. without it, sections, segments and resources get written below<file>.sections,<file>.segmentsand<file>.resourcesrespectively. sub-binaries keep the traditional<file>.fatdirectory.-X format file ...β package the given files in fat or zip-zβ strings (from data section)-Zβ guess the size of the binary program-zzβ show strings from raw bins-zzzβ dump raw strings to stdout (for huge files)
π ENVIRONMENT π
R2_NOPLUGINSβ same asr2 -N. do not load shared pluginsR2_PLUGINS_ORDERβ plugin load order:i=internal,e=env,h=home,s=system; default=iehs;?prints helpRABIN2_ARGSβ ignore the CLI and use these arguments insteadRABIN2_CHARSETβ set the default value charset for-zstringsRABIN2_DEBASE64β same asr2 -e bin.str.debase64β try to decode all strings as base64 if possibleRABIN2_DEMANGLEβ same asr2 -e bin.demangleβ demangle symbolsRABIN2_DEMANGLE_CMDβ same asr2 -e bin.demangle.cmdβ try to purge false positivesRABIN2_DEMANGLE_TRYLIBβ same asr2 -e bin.demangle.trylib=<bool>β load Swift libs to demangle (default:false)RABIN2_FILTERβ same asr2 -e bin.filter=<bool>β set tofalseto not rename duplicated symbols/sections (default:true)RABIN2_LANGβ same asr2 -e bin.langβ assume lang for demanglingRABIN2_MACHO_NOFUNCSTARTSβ if set, it will ignore the FUNCSTART informationRABIN2_MACHO_NOSWIFTβ avoid parsing the swift metadataRABIN2_MACHO_SKIPFIXUPSβ do not parse the mach-o chained fixupsRABIN2_MAXSTRBUFβ same asr2 -e bin.str.maxbufβ specify maximum buffer sizeRABIN2_PDBSERVERβ same asr2 -e pdb.serverβ use an alternative PDB serverRABIN2_PREFIXβ same asr2 -e bin.prefixβ prefix symbols/sections/relocs with a specific stringRABIN2_RESRAWβ same asr2 -e bin.resraw=trueβ extract resources without decoding their contentsRABIN2_STRFILTERβ same asr2 -e bin.str.filterRABIN2_STRPURGEβ same asr2 -e bin.str.purgeβ try to purge false positivesRABIN2_SYMSTOREβ same asr2 -e pdb.symstoreβ path to downstream symbol storeRABIN2_VERBOSEβ same asr2 -e bin.verbose=trueβ show debugging messages from the parser
π EXAMPLES π
list the symbols of a program β classic, iconic:
$ rabin2 -s a.out
get the offset of a symbol:
$ rabin2 -n _main a.out
get the entrypoint:
$ rabin2 -e a.out
load symbols and imports from radare2:
$ r2 -n /bin/ls
[0x00000000]> .!rabin2 -prsi $FILE
π SEE ALSO π
radare2(1) β go say hi to her big sister π
π§ AUTHORS π§
written by pancake <pancake@nopcode.org>. king behaviour, fr fr. π
that's the whole page, bestie β no gatekeeping, everything's in there. β¨
and a lil sign-off: this page is RABIN2(1), dated July 14, 2026. mwah π π
π¦ where this page comes from
- arch rolling: radare2 6.2.2-1 Β· GPL-3.0-only AND LGPL-3.0-only
- opensuse-leap 16.0: radare2 6.2.2-bp160.1.1 Β· GPL-3.0-only AND LGPL-3.0-only
- opensuse-leap 16.0: radare2 6.2.2-bp160.1.1 Β· GPL-3.0-only AND LGPL-3.0-only
- opensuse-leap 16.0: radare2 6.2.2-bp160.1.1 Β· GPL-3.0-only AND LGPL-3.0-only
- opensuse-leap 16.0: radare2 6.2.2-bp160.1.1 Β· GPL-3.0-only AND LGPL-3.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms