All Projects → cesena → ghidra2dwarf

cesena / ghidra2dwarf

Licence: MIT license
🐉 Export ghidra decompiled code to dwarf sections inside ELF binary

Programming Languages

python
139335 projects - #7 most used programming language
java
68154 projects - #9 most used programming language
c
50402 projects - #5 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to ghidra2dwarf

Pwninit
pwninit - automate starting binary exploit challenges
Stars: ✭ 127 (-5.93%)
Mutual labels:  pwn, elf
Exrop
Automatic ROPChain Generation
Stars: ✭ 191 (+41.48%)
Mutual labels:  pwn, ctf
Glibc All In One
🎁A convenient glibc binary and debug file downloader and source code auto builder
Stars: ✭ 145 (+7.41%)
Mutual labels:  pwn, ctf
Ctf Pwn Tips
Here record some tips about pwn. Something is obsoleted and won't be updated. Sorry about that.
Stars: ✭ 1,249 (+825.19%)
Mutual labels:  pwn, ctf
ghidra-r2web
Ghidra plugin to start an r2 webserver to let r2 interact with it
Stars: ✭ 38 (-71.85%)
Mutual labels:  decompiler, ghidra
One gadget
The best tool for finding one gadget RCE in libc.so.6
Stars: ✭ 1,306 (+867.41%)
Mutual labels:  pwn, ctf
Ctf
CTF write-ups and some wargame sites write-ups.
Stars: ✭ 157 (+16.3%)
Mutual labels:  pwn, ctf
Write Ups
📚 VoidHack CTF write-ups
Stars: ✭ 45 (-66.67%)
Mutual labels:  pwn, ctf
Ctf All In One
CTF竞赛权威指南
Stars: ✭ 2,807 (+1979.26%)
Mutual labels:  pwn, ctf
House Of Corrosion
A description of the "House of Corrosion" GLIBC heap exploitation technique.
Stars: ✭ 202 (+49.63%)
Mutual labels:  pwn, ctf
Pwn Sandbox
A sandbox to protect your pwn challenges being pwned in CTF AWD.
Stars: ✭ 81 (-40%)
Mutual labels:  pwn, ctf
Fcd
An optimizing decompiler
Stars: ✭ 622 (+360.74%)
Mutual labels:  decompiler, elf
Slides
won't maintain
Stars: ✭ 79 (-41.48%)
Mutual labels:  pwn, ctf
2018 Qwb Ctf
2018强网杯CTF___题目整理
Stars: ✭ 106 (-21.48%)
Mutual labels:  pwn, ctf
Libc Database
Build a database of libc offsets to simplify exploitation
Stars: ✭ 1,122 (+731.11%)
Mutual labels:  pwn, ctf
Pwn Env Init
CTF PWN 做题环境一键搭建脚本
Stars: ✭ 147 (+8.89%)
Mutual labels:  pwn, ctf
Ctf Tools
CTF 工具集合
Stars: ✭ 524 (+288.15%)
Mutual labels:  pwn, ctf
Shellen
🌸 Interactive shellcoding environment to easily craft shellcodes
Stars: ✭ 799 (+491.85%)
Mutual labels:  pwn, ctf
Build An Efficient Pwn Environment
How to build an efficient pwn development environment in 2020
Stars: ✭ 191 (+41.48%)
Mutual labels:  pwn, ctf
sleigh
Unofficial CMake build for Ghidra SLEIGH
Stars: ✭ 54 (-60%)
Mutual labels:  decompiler, ghidra

Ghidra2Dwarf

Inspired by: dwarfexport

Contributions are welcome, feel free to open an issue if something is broken.

Ghidra2Dwarf is a ghidra plugin that allows to exports informations (such as functions, decompiled code, types) from ghidra to dwarf sections inside ELF binaries.

More specifically it exports inside a source file named ${program}_dbg.c all the decompiled functions, and create an ELF binary named ${program}_dbg that can be used to do source code level debugging.

Example:

Inside gdb now you can use:

  1. list <function> to display the function's source code.
  2. n to step one source code line instruction.
  3. ni to step one assembly instruction.
  4. p variable to print the variable's value.

Install

  • Unzip the latest release.
  • In the script manager -> script directories add the extracted directory:

Run

Run ghidra2dwarf.py inside the script manager:

Headless mode

This mode only works in ghidra 9.1.2 at the moment NationalSecurityAgency/ghidra#2561

Linux

If you saved the project and ghidra is closed, you can launch ghidra2dwarf.sh to run ghidra in headless mode and export the dwarf informations:

$ ./src/ghidra2dwarf.sh <Project directory> <Project name> <Binary path> <Binary>
$ # Example: ./src/ghidra2dwarf.sh ~/.local/share/ghidra/ TEST ~/CTF/ chall

Windows

TODO

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].