rizin
Framework open-source de rétro-ingénierie. Fork de radare2 avec une expérience utilisateur améliorée. Désassemble, débogue, analyse et édite des binaires. Inclut Cutter comme interface graphique. Open-source reverse engineering framework. Fork of radare2 with improved UX. Disassembles, debugs, analyzes, and edits binaries. Includes Cutter as a graphical frontend.
↗ https://rizin.reOverview
rizin is a fork of radare2 with a focus on improved user experience, clean APIs, and consistent commands. It’s a full-featured reverse engineering framework: disassembler, debugger, binary editor, and scriptable analysis platform. Cutter is its official graphical frontend.
Basic Usage
Open a binary for analysis
rizin ./binary
rizin -A ./binary # Analyze all (functions, strings, etc.)
rizin -a ./binary # Analyze and run auto-analysis
Open in write mode
rizin -w ./binary
Open a file at specific offset
rizin -s 0x401000 ./binary
Debug mode
rizin -d ./binary
Core Commands
[0x00401000]> aaa # analyze all
[0x00401000]> aa # analyze and detect functions
[0x00401000]> s main # seek to main function
[0x00401000]> s 0x401234 # seek to address
[0x00401000]> pdf # print disassembly of function
[0x00401000]> pd 20 # print 20 disassembled instructions
[0x00401000]> px 64 # print 64 bytes hexdump
[0x00401000]> iz # list strings in data section
[0x00401000]> izz # list all strings in binary
[0x00401000]> / "/bin/sh" # search for string
[0x00401000]> afl # list all functions
[0x00401000]> afn main 0x401234 # rename function
[0x00401000]> i # binary info
[0x00401000]> ii # imports
[0x00401000]> iS # sections
[0x00401000]> is # symbols
Debugging
Start debugging
rizin -d ./binary
[0x00401000]> dc # continue execution
[0x00401000]> dso # step over
[0x00401000]> dsi # step into
[0x00401000]> db 0x401234 # set breakpoint
[0x00401000]> dbl # list breakpoints
[0x00401000]> dr # print registers
[0x00401000]> dr rsp # print specific register
ROP Gadgets
Find ROP gadgets
[0x00401000]> /R pop rdi
Find all ret gadgets
[0x00401000]> /R ret
Search for gadget patterns
[0x00401000]> /R pop r??; ret
Scripting
Rizin scripting
rizin -q ./binary -c "aaa; afl"
With rizin pipe
rz-pipe ./binary "aaa" "afl"
# Python scripting with rzpipe
python3 -c "
import rzpipe
r = rzpipe.open('./binary')
r.cmd('aaa')
functions = r.cmdj('aflj')
for f in functions:
print(f['name'], hex(f['offset']))
"
Cutter (Graphical Frontend)
Install Cutter
sudo apt install rizin-cutter
Launch Cutter
cutter
# Cutter features:
# - Graph view for control flow
# - Decompiler (with rz-ghidra plugin)
# - Hex editor
# - Strings, imports, exports panels
# - Scripting console
Tips
- Use
aaafor full analysis,aafor faster basic analysis pdf(print disassembly of function) is the most used command after seeking- The Cutter GUI is recommended for initial binary exploration before deep diving in CLI
- Use
rz-ghidraplugin for decompilation directly in rizin/Cutter
Quick Command Reference
s <addr> Seek to address
pd N Print N disassembled instructions
pdf Print disassembly of current function
afl List all analyzed functions
iz List strings in data section
ii List imports
iS List sections
dr Print registers
db <addr> Set breakpoint
dc Continue execution
/R <instr> Search for ROP gadget
px N Hexdump N bytes
i Binary information
Vue d’ensemble
rizin est un fork de radare2 axé sur une expérience utilisateur améliorée, des API propres et des commandes cohérentes. C’est un framework de rétro-ingénierie complet : désassembleur, débogueur, éditeur binaire et plateforme d’analyse scriptable. Cutter est son interface graphique officielle.
Utilisation basique
Ouvrir un binaire pour analyse
rizin ./binary
rizin -A ./binary # Analyser tout (fonctions, chaînes, etc.)
rizin -a ./binary # Analyser et lancer l'auto-analyse
Ouvrir en mode écriture
rizin -w ./binary
Ouvrir un fichier à un offset spécifique
rizin -s 0x401000 ./binary
Mode débogage
rizin -d ./binary
Commandes de base
[0x00401000]> aaa # analyser tout
[0x00401000]> aa # analyser et détecter les fonctions
[0x00401000]> s main # se positionner sur la fonction main
[0x00401000]> s 0x401234 # se positionner sur une adresse
[0x00401000]> pdf # afficher le désassemblage de la fonction
[0x00401000]> pd 20 # afficher 20 instructions désassemblées
[0x00401000]> px 64 # afficher un hexdump de 64 octets
[0x00401000]> iz # lister les chaînes dans la section de données
[0x00401000]> izz # lister toutes les chaînes du binaire
[0x00401000]> / "/bin/sh" # rechercher une chaîne
[0x00401000]> afl # lister toutes les fonctions
[0x00401000]> afn main 0x401234 # renommer une fonction
[0x00401000]> i # informations sur le binaire
[0x00401000]> ii # imports
[0x00401000]> iS # sections
[0x00401000]> is # symboles
Débogage
Démarrer le débogage
rizin -d ./binary
[0x00401000]> dc # poursuivre l'exécution
[0x00401000]> dso # step over
[0x00401000]> dsi # step into
[0x00401000]> db 0x401234 # placer un point d'arrêt
[0x00401000]> dbl # lister les points d'arrêt
[0x00401000]> dr # afficher les registres
[0x00401000]> dr rsp # afficher un registre spécifique
Gadgets ROP
Trouver des gadgets ROP
[0x00401000]> /R pop rdi
Trouver tous les gadgets ret
[0x00401000]> /R ret
Rechercher des schémas de gadgets
[0x00401000]> /R pop r??; ret
Scripting
Scripting rizin
rizin -q ./binary -c "aaa; afl"
Avec rizin pipe
rz-pipe ./binary "aaa" "afl"
# Scripting Python avec rzpipe
python3 -c "
import rzpipe
r = rzpipe.open('./binary')
r.cmd('aaa')
functions = r.cmdj('aflj')
for f in functions:
print(f['name'], hex(f['offset']))
"
Cutter (interface graphique)
Installer Cutter
sudo apt install rizin-cutter
Lancer Cutter
cutter
# Fonctionnalités de Cutter :
# - Vue graphe pour le flux de contrôle
# - Décompilateur (avec le plugin rz-ghidra)
# - Éditeur hexadécimal
# - Panneaux chaînes, imports, exports
# - Console de scripting
Conseils
- Utiliser
aaapour une analyse complète,aapour une analyse basique plus rapide pdf(afficher le désassemblage de la fonction) est la commande la plus utilisée après un déplacement- L’interface Cutter est recommandée pour l’exploration initiale d’un binaire avant de plonger en CLI
- Utiliser le plugin
rz-ghidrapour la décompilation directement dans rizin/Cutter
Référence rapide des commandes
s <addr> Seek to address
pd N Print N disassembled instructions
pdf Print disassembly of current function
afl List all analyzed functions
iz List strings in data section
ii List imports
iS List sections
dr Print registers
db <addr> Set breakpoint
dc Continue execution
/R <instr> Search for ROP gadget
px N Hexdump N bytes
i Binary information