diff options
author | Johannes Stoelp <johannes.stoelp@gmail.com> | 2022-04-30 19:42:48 +0200 |
---|---|---|
committer | Johannes Stoelp <johannes.stoelp@gmail.com> | 2022-04-30 19:42:48 +0200 |
commit | f33fbacc6aaa54599458ac3eb375708650656010 (patch) | |
tree | aafc198b639dc9b9fa65ec0b7e20c2460ca2d80d /src/tools | |
parent | ff71b8bab603e9582899e2c8ad8653dcc86ea6c4 (diff) | |
download | notes-f33fbacc6aaa54599458ac3eb375708650656010.tar.gz notes-f33fbacc6aaa54599458ac3eb375708650656010.zip |
r2: add example rasm and patch file
Diffstat (limited to 'src/tools')
-rw-r--r-- | src/tools/radare2.md | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/tools/radare2.md b/src/tools/radare2.md index 673c911..2a903da 100644 --- a/src/tools/radare2.md +++ b/src/tools/radare2.md @@ -25,3 +25,24 @@ > r2 -B <baddr> <exe> # open <exe> mapped to addr <baddr> oob <addr> # reopen current file at <baddr> ``` + +# Examples + +## Patch file (alter bytes) +```markdown + > r2 [-w] <file> + oo+ # re-open for write if -w was not passed + s <addr> # seek to position + wv <data> # write 4 byte (dword) +``` + +## Assemble / Disassmble (rasm2) +```markdown + rasm2 -L # list supported archs + + > rasm2 -a x86 'mov eax, 0xdeadbeef' + b8efbeadde + + > rasm2 -a x86 -d "b8efbeadde" + mov eax, 0xdeadbeef +``` |