Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/patois/hrdevhelper
HexRays ctree visualization plugin
https://github.com/patois/hrdevhelper
ast ctree debugging decompiler graph hexrays hexrays-decompiler ida ida-pro idapython visualization
Last synced: 3 months ago
JSON representation
HexRays ctree visualization plugin
- Host: GitHub
- URL: https://github.com/patois/hrdevhelper
- Owner: patois
- License: other
- Created: 2019-05-23T17:54:25.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-04-12T19:33:57.000Z (over 1 year ago)
- Last Synced: 2024-07-31T23:46:08.008Z (4 months ago)
- Topics: ast, ctree, debugging, decompiler, graph, hexrays, hexrays-decompiler, ida, ida-pro, idapython, visualization
- Language: Python
- Homepage:
- Size: 1020 KB
- Stars: 363
- Watchers: 16
- Forks: 34
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# HRDevHelper
HRDevHelper is an extension for the Hexrays decompiler written in IDAPython and is meant to be a helpful tool for debugging and developing your own Hexrays plugins and scripts. The plugin draws its usefulness from displaying a graph of a decompiled function's respective ctree and creating visual links between its underlying decompiled code and the graphs' individual items.
![HRDevHelper animated gif](/rsrc/hrdevhelper.gif?raw=true)
When invoked, HRDevHelper creates and attaches a ctree graph to the currently active decompiler widget and centers the graph's view on the current ctree item. Subsequently navigating the decompiled code visually highlights corresponding ctree items in the graph.
The plugin's default colors and other settings (zoom, dock position etc.) can be configured by
editing the plugin's configuration file that is created after running the plugin for the first time. The HRDevhelper.cfg configuration file can be found in the [IDA user directory](https://hex-rays.com/blog/igors-tip-of-the-week-33-idas-user-directory-idausr/).## Installation
Copy hrdevhelper.py and the hrdh folder to ./IDA/plugins/ and restart IDA.## Plugin Usage & Shortcuts
The plugin's functionality is accessible via right-click in a decompiler view or otherwise via keyboard shortcuts:* "show ctree" creates a graph of all ctree items of the current decompiled function.
* "show sub-tree" creates a graph of ctree items that belong to the current expression.
The subgraph's root is determined via the current decompiler view's text cursor.
* "show context" opens a context viewer that, among other information, displays the current
sub-tree's citems as a lambda expression. This expression can be used with and directly copy-pasted into hxtb-shell that comes with the [HexraysToolbox](https://github.com/patois/HexraysToolbox) script.By default, HRDevHelper visually highlights all ctree items in a graph that correspond to a current single decompiled line of code. Making a selection of multiple lines highlights nodes accordingly.
The two screenshots below show the context viewer.
![HRDevHelper context view](/rsrc/hrdevctx.png?raw=true)
![HRDevHelper context view](/rsrc/hrdevctx2.png?raw=true)
In addition to the keyboard shortcuts that are made available in decompiler views, the graphs created by HRDevHelper have additional keyboard shortcuts in place as shown below.
### Graph Hotkeys (focus on any HRDevHelper graph/subgraph):
* C: Toggle "center on current item/node" functionality (switches synchronization on/off).
* D: Increase debug/verbosity of particular nodes