A simple x86_64 debugger written with ptrace and Udis86
db depends on Udis86 to provide
disassembly. This is an essential feature of any debugger, so the dependency is
In order to build
libcis POSIX.1-2008 compliant
There is no configure step, and no install target, so simply run:
db accepts only positional arguments: the command-line of the program to be
Assuming you have placed the
db executable somewhere in your
Prompts begin with
(db) , and have limited line-editing support.
Errors are printed before the next prompt.
All commands in
db are identified as a single character mnemonic, followed by
db supports the following commands:
commands: s | step single instruction d | dissassemble current instruction r <reg> | read register w <reg> <val> | write register g <adr> | get memory p <adr> <val> | poke memory e | exit registers: r15 r14 r13 r12 rbp rbx r11 r10 r9 r8 rax rcx rdx rsi rdi orig_rax rip cs eflags rsp ss fs_base gs_base ds es fs gs
Values and addresses are expected to be in hexadecimal.
Desired features include:
- Visual (TUI) mode
- Arbitrary code execution while single-stepping