diff --git a/FEATURES.md b/FEATURES.md index 506ea7ae..6ad82bc1 100644 --- a/FEATURES.md +++ b/FEATURES.md @@ -91,20 +91,21 @@ cwatch execute "x/20x $rsp" ### Ghidra -With the help of [radare2](https://github.com/radareorg/radare2) it is possible to show the +With the help of [radare2](https://github.com/radareorg/radare2) or [rizin](https://github.com/rizinorg/rizin) it is possible to show the decompiled source code of the ghidra decompiler. However, this comes with some prerequisites. -* First: you have to have installed radare2 and it must be found by gdb (within path) +* First: you have to have installed radare2 or rizin and it must be found by gdb (within path) * Second: you have to install the ghidra plugin for radare2 - [r2ghidra-dec](https://github.com/radareorg/r2ghidra-dec) -* Third: r2pipe has to be installed in the python-context gdb is using + [r2ghidra](https://github.com/radareorg/r2ghidra) or install the ghidra plugin for rizin [rz-ghidra](https://github.com/rizinorg/rz-ghidra) + +* Third: r2pipe has to be installed in the python-context gdb is using (or if you are using rizin, install rzpipe instead) The decompiled source be shown as part of the context by adding `ghidra` to `set context-sections` or by calling `ctx-ghidra [function]` manually. -Be warned, the first call to radare2/r2ghidra-dec is rather slow! Subsequent requests for decompiled -source will be faster. And it does take up some resources as the radare2 instance is kept by r2pipe +Be warned, the first call to both radare2/r2ghidra and rizin/rz-ghidra are rather slow! Subsequent requests for decompiled +source will be faster. And it does take up some resources as the radare2/rizin instance is kept by r2pipe/rzpipe to enable faster subsequent analysis. With those performance penalties it is reasonable to not have it launch always. Therefore it includes diff --git a/docs/commands/misc/rz.md b/docs/commands/misc/rz.md new file mode 100644 index 00000000..d4ab51d5 --- /dev/null +++ b/docs/commands/misc/rz.md @@ -0,0 +1,17 @@ +## Command: rz ## +``` +usage: rz [-h] [--no-seek] [arguments [arguments ...]] +``` +Launches rizin + +| Positional Argument | Info | +|---------------------|------| +| arguments | Arguments to pass to radare | + +| Optional Argument | Info | +|---------------------|------| +| --help | show this help message and exit | +| --no-seek | Do not seek to current pc (default: False) | + + +Example: rz -- -S -AA diff --git a/pwndbg/commands/context.py b/pwndbg/commands/context.py index 873d3295..e3cc2328 100644 --- a/pwndbg/commands/context.py +++ b/pwndbg/commands/context.py @@ -327,7 +327,7 @@ def context_expressions(target=sys.stdout, with_banner=True, width=None): config_context_ghidra = pwndbg.gdblib.config.add_param( "context-ghidra", "never", - "when to try to decompile the current function with ghidra (slow and requires radare2/r2pipe) (valid values: always, never, if-no-source)", + "when to try to decompile the current function with ghidra (slow and requires radare2/r2pipe or rizin/rzpipe) (valid values: always, never, if-no-source)", )