From 1aa2ec6e69ffeb80571960ad20a0fbc37200da4d Mon Sep 17 00:00:00 2001 From: pancake Date: Wed, 12 Jan 2022 15:46:49 +0100 Subject: [PATCH] Add 'first session' example in the README ##doc --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index c1019c83a1..dc3c4aab2a 100644 --- a/README.md +++ b/README.md @@ -37,6 +37,24 @@ r2env init r2env add radare2@git ``` +## Usage + +These are the first steps to use r2, read the book or find tutorials for more details + +```sh +$ r2 /bin/ls # open the binary in read-only mode +> aaa # same as r2 -A, analyse the binary +> afl # list all functions (try aflt, aflm) +> px 32 # print 32 byte hexdump current block +> s sym.main # seek to the given offset (by flag name, number, ..) +> f~foo # filter flags with ~grep (same as |grep) +> iS;is # list sections and symbols (same as rabin2 -Ss) +> pdf; agf # print function and show control-flow-graph in ascii-art +> oo+;w hello # reopen in rw mode and write a string in the current offset +> ?*~... # interactive filter all command help messages +> q # quit +``` + ## Resources * [Official radare2 book](https://book.rada.re): Read about r2 usage.