Skip to content

Commit

Permalink
Update dereference.md (#773)
Browse files Browse the repository at this point in the history
Add compulsory arguments to `dereference`
  • Loading branch information
szotsaki committed Dec 25, 2021
1 parent d98ffb7 commit 08f4b28
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/commands/dereference.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ gef➤ dereference
Here is an example with arguments:

```
gef➤ telescope $rbp+0x10 8
gef➤ telescope $rbp+0x10 -l 8
0x00007fffffffdf40│+0x0000: 0x00007ffff7fa5760 → 0x00000000fbad2887
0x00007fffffffdf48│+0x0008: 0x00000001f7e65b63
0x00007fffffffdf50│+0x0010: 0x0000000000000004
Expand All @@ -49,7 +49,7 @@ context (on a 64bit architecture):
```
gef➤ p ($rbp - $rsp)/8
$3 = 4
gef➤ dereference 5
gef➤ dereference -l 5
0x00007fffffffe170│+0x0000: 0x0000000000400690 → push r15 ← $rsp
0x00007fffffffe178│+0x0008: 0x0000000000400460 → xor ebp, ebp
0x00007fffffffe180│+0x0010: 0x00007fffffffe270 → 0x1
Expand All @@ -61,7 +61,7 @@ It is possible to change the offset calculation to use a different address than
the start address:

```
gef➤ dereference $sp l7 r$rbp
gef➤ dereference $sp -l 7 -r $rbp
0x00007ffe6ddaa3e0│-0x0030: 0x0000000000000000 ← $rsp
0x00007ffe6ddaa3e8│-0x0028: 0x0000000000400970 → <__libc_csu_init+0> push r15
0x00007ffe6ddaa3f0│-0x0020: 0x0000000000000000
Expand Down

0 comments on commit 08f4b28

Please sign in to comment.