• Stars
    star
    20,356
  • Rank 1,236 (Top 0.03 %)
  • Language
    C
  • License
    GNU Lesser Genera...
  • Created over 12 years ago
  • Updated 3 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

UNIX-like reverse engineering framework and command-line toolset

screenshot

Radare2: Libre Reversing Framework for Unix Geeks

Latest packaged version Tests Status build tcc CII Best Practices Build Status Discord

See the Releases page for downloads. The current git master branch is 5.9.1, next will be 5.9.2.

  • Since r2-5.6.0 all the patch releases are abi stable
  • Odd patch versions are used in git builds only, releases use even numbers
  • No need to recompile the plugins, bindings or tools if the major and minor version are the same

Description

r2 is a complete rewrite of radare. It provides a set of libraries, tools and plugins to ease reverse engineering tasks. Distributed mostly under LGPLv3, each plugin can have different licenses (see r2 -L, rasm2 -L, ...).

The radare project started as a simple command-line hexadecimal editor focused on forensics. Today, r2 is a featureful low-level command-line tool with support for scripting with the embedded Javascript interpreter or via r2pipe.

r2 can edit files on local hard drives, view kernel memory, and debug programs locally or via a remote gdb/windbg servers. r2's wide architecture support allows you to analyze, emulate, debug, modify, and disassemble any binary.

screenshot

Installation

The recommended way to install radare2 is via Git using acr/make or meson:

git clone https://github.com/radareorg/radare2
radare2/sys/install.sh

On Windows you may want to use the precompiled builds or the .bat files to compile if you have msvc:

preconfigure.bat       REM setup python, meson, ninja
configure.bat          REM run meson b + vs project
make.bat               REM run ninja -C b
prefix\bin\radare2.exe
  • r2 can be installed from git or via pip using r2env.
  • Run sys/install.sh for the default acr+make+symlink installation
  • meson/ninja (muon/samu also works) and make builds are supported.
  • Windows builds require meson and msvc or mingw as compilers
  • To uninstall the current build of r2 run make uninstall
  • To uninstall ALL the system installations of r2 do: sudo make purge

Popular Plugins:

Using the r2pm tool you can browse and install many plugins and tools that use radare2.

  • esilsolve: The symbolic execution plugin, based on esil and z3
  • iaito: The official Qt graphical interface
  • keystone Assembler instructions using the Keystone library
  • r2ai Run a Language Model in localhost with Llama inside r2!
  • r2dec: A decompiler based on r2 written in JS, accessed with the pdd command
  • r2diaphora: Diaphora's diffing engine working on top of radare2
  • r2frida: The frida io plugin. Start r2 with r2 frida://0 to use it
  • r2ghidra: The native ghidra decompiler plugin, accessed with the pdg command
  • r2papi High level api on top of r2pipe
  • r2pipe Script radare2 from any programming language
  • r2poke Integration with GNU/Poke for extended binary parsing capabilities
  • r2yara Run Yara from r2 or use r2 primitives from Yara
  • radius2: A fast symbolic execution engine based on boolector and esil
  • r2sarif import/export SARIF documents, streamlining vulnerability reporting and visualization in binaries

Usage

These are the first steps to use r2, read the book or find tutorials for more details

$ r2 /bin/ls   # open file in read-only
> aaa          # analyse the program (r2 -A)
> afl          # list all functions (try aflt, aflm)
> px 32        # print 32 byte hexdump current block
> s sym.main   # seek to main (using flag name)
> f~foo        # filter flags matching 'foo' (internal |grep)
> iS;is        # list sections and symbols (rabin2 -Ss)
> pdf; agf     # disassembly and ascii-art function graph
> oo+;w hello  # reopen in read-write and write a string
> ?*~...       # interactive filter in all command help
> q            # quit

Many plugins are included in r2 by default. But you can extend its capabilities by using the r2pm package manager.

r2pm -s <word>  # search packages matching a word
r2pm -Uci <pkg> # update database and clean install a package
r2pm -u <pkg>   # uninstall the given package
r2pm -l <pkg>   # list installed packages

Resources

Documentation

Learn more about r2 watching youtube talks from r2con. There are also many blogposts, slidedecks and the official radare2 book, but it's always a good idea to join any of the official chats and drop your questions/feedback around.

Community

Supported Platforms

Operating Systems

Windows (since XP), Linux, Darwin, GNU/Hurd, Apple's {Mac,i,iPad,watch}OS, Android, [Dragonfly, Net, Free, Open] BSD, Z/OS, QNX, SerenityOS, Solaris, Haiku, Vinix, FirefoxOS.

Architectures

i386, x86-64, Alpha, ARM, AVR, BPF, MIPS, PowerPC, SPARC, RISC-V, SH, m68k, S390, XCore, CR16, HPPA, ARC, Blackfin, Z80, H8/300, V810, PDP11, m680x, V850, CRIS, XAP (CSR), PIC, LM32, 8051, 6502, i4004, i8080, Propeller, EVM, OR1K Tricore, CHIP-8, LH5801, T8200, GameBoy, SNES, SPC700, MSP430, Xtensa, xcore, NIOS II, Java, Dalvik, Pickle, WebAssembly, MSIL, EBC, TMS320 (c54x, c55x, c55+, c64x), Hexagon, Brainfuck, Malbolge, whitespace, DCPU16, LANAI, lm32, MCORE, mcs96, RSP, SuperH-4, VAX, KVX, Am29000, LOONGARCH, JDH8, s390x.

File Formats

ELF, Mach-O, Fatmach-O, PE, PE+, MZ, COFF, XCOFF, OMF, TE, XBE, SEP64, BIOS/UEFI, Dyldcache, DEX, ART, Java class, Android boot image, Plan9 executables, Amiga HUNK, ZIMG, MBN/SBL bootloader, ELF coredump, MDMP (Windows minidump), PDP11, XTAC, CGC, WASM (WebAssembly binary), Commodore VICE emulator, QNX, WAD, OFF, TIC-80, GB/GBA, NDS and N3DS, and mount several filesystems like NTFS, FAT, HFS+, EXT,...

Packaging Status

  • Snap package
  • Termux package
  • Alpine Linux Edge package Alpine Linux 3.13 package Alpine Linux 3.12 package
  • Arch package AUR package
  • EPEL 7 package
  • EPEL 8 package
  • EPEL 9 package
  • Fedora Dev Fedora 36 Fedora 34
  • FreeBSD port OpenBSD port pkgsrc current package
  • Homebrew package MacPorts package
  • Haiku Ports Void Linux
  • Ubuntu 20.04 package Ubuntu 18.04 package
  • Debian Unstable package Raspbian Stable package Kali Linux Rolling package

More Repositories

1

iaito

Official QT frontend of radare2
C++
1,047
star
2

radare2-book

The Official Radare2 Book
C
787
star
3

awesome-radare2

A curated list of awesome projects, articles and the other materials powered by Radare2
696
star
4

radeco

radare2-based decompiler and symbol executor
Rust
372
star
5

radare2-r2pipe

Access radare2 via pipe from any programming language!
JavaScript
370
star
6

r2ghidra

Native Ghidra Decompiler for r2
C++
334
star
7

radare2-extras

Source graveyard and random candy for radare2
C
239
star
8

sdb

Simple and fast string based key-value database with support for arrays and json
C
216
star
9

r2con

Radare Congress Stuff
202
star
10

esilsolve

A python symbolic execution framework using radare2's ESIL (Evaluable String Intermediate Language)
Python
159
star
11

r2con2019

r2con2019 - slides and materials
Python
135
star
12

radare2-pm

Package Manager for Radare2
Shell
131
star
13

radare2-bindings

Bindings of the r2 api for Valabind and friends
Python
130
star
14

r2retdec

RetDec plugin for Radare2
C++
123
star
15

r2con2017

r2con 2017 September 6-9
Python
97
star
16

radare2-webui

webui repository for radare2
JavaScript
93
star
17

r2con2018

HTML
92
star
18

r2ai

local language model for radare2
Python
78
star
19

r2wars

Corewars but within r2
C#
56
star
20

r2pipe.rs

Rust crate for r2pipe
Rust
44
star
21

ghidra-r2web

Ghidra plugin to start an r2 webserver to let r2 interact with it
Java
43
star
22

libdemangle

A simple library focusing on demangling symbols for different programing languages
C
39
star
23

r2con2020

Python
35
star
24

radare

advanced unix-like hexadecimal editor and debugger
C
35
star
25

r2jp

Japanese Community of radare2
34
star
26

r2pm

Radare2 cross platform package manager
Go
33
star
27

radare2-r2papi

High Level API on top of the R2Pipe interface
TypeScript
33
star
28

acr

autoconf replacement
Shell
33
star
29

r2pipe-go

Go API to interact with radare2
Go
31
star
30

ghidra-native

C++
29
star
31

r2con2021

28
star
32

r2env

Install multiple versions of r2 and its plugins via Pip on any system!
Python
25
star
33

r2yara

yara and radare2, better together
C
17
star
34

radare2-rlang

Writing Radare2 plugins in various languages
C
15
star
35

radare2-testbins

Rebol
15
star
36

radare2-rust

Playground for Rust and Radare2
Rust
14
star
37

radare.org

http://www.radare.org/
CSS
14
star
38

r2hexagon

Hexagon disassembler code generator from the official instruction manual.
C
11
star
39

r2con2016

r2con2016 repository
C
10
star
40

esil-rs

Radare2's ESIL in Rust
Rust
10
star
41

r2diaphora

Binary Diffing tool ported to radare2
Python
9
star
42

radare2-gsoc-windows

Various Brainstorming/scripts/ideas/etc. for the GSOC-Windows Task
C
9
star
43

ragui

Vala
8
star
44

radare2-release

Releasing is hard
Shell
7
star
45

r2app

Electron Desktop App for Radare2
JavaScript
6
star
46

blog

The radare2 blog, available on radare.today
Shell
6
star
47

r2pipe-codeshare

A place to share your radare2 scripts
Python
6
star
48

radare2-win-installer

Windows installer scripts for radare2
Inno Setup
5
star
49

r2r-go

Go
5
star
50

radareorg

New amazing website for radare.org
Python
4
star
51

radare2-cheatsheets

TeX
4
star
52

radare2-fuzz

Python
4
star
53

ideas

4
star
54

radare2-skel

Sample radare2 project templates
Python
4
star
55

node-r2r

radare2 regressions testsuite in nodejs
JavaScript
3
star
56

iaito-translations

Makefile
3
star
57

.github

Radare Organization Templates
3
star
58

r2shell

C
2
star
59

infrastructure

Terraform, Nomad, Consul and Vault configuration of radare infrastructure
Dockerfile
2
star
60

r2pm-db

Radare2 package manager database
2
star
61

radare2-snap

Radare2 snap and docker repository
Makefile
2
star
62

radare2-fuzztargets

Makefile
1
star
63

r2r-v

R2 regressions testsuite written in V
V
1
star
64

radeco-regressions

Regresion tests for radeco
Rust
1
star
65

radare2-sigs

Zignature masm32 repository
Python
1
star
66

r2sarif

Load, manage and create SARIF documents with radare2
TypeScript
1
star