2023-01-16 19:02:44 +01:00
|
|
|
# GDB CheatSheet
|
|
|
|
|
|
|
|
## Cast a register value
|
|
|
|
|
|
|
|
* Cast the content of a register to char
|
|
|
|
```sh
|
|
|
|
p *(char **)$rax
|
|
|
|
```
|
2023-04-05 19:38:01 +02:00
|
|
|
|
|
|
|
## Show Instructions
|
|
|
|
|
|
|
|
Show the next 70 instructions under the current position
|
|
|
|
```sh
|
|
|
|
x/70i $pc
|
|
|
|
```
|
2023-04-05 19:42:49 +02:00
|
|
|
|
|
|
|
## Set Breakpoint
|
|
|
|
|
|
|
|
Set breakpoint to address
|
|
|
|
```sh
|
|
|
|
b *0xdeadbeef
|
|
|
|
```
|