
hilft bei der Visualisierung von Heap-Operationen für Pwn und Debugging
heaptrace ist ein Heap-Debugger zur Verfolgung von glibc-Heap-Operationen in ELF64 (x86_64)-Binärdateien. Sein Zweck ist es, Heap-Operationen beim Debuggen von Binärdateien oder beim Heap-Pwn zu visualisieren.

--break)Wie unterscheiden sich heaptrace und valgrind?
Siehe die .deb- und .rpm-Release-Dateien sowie eine vorkompilierte Binärdatei auf der Releases-Seite.
$ sudo add-apt-repository ppa:arinerron/heaptrace
$ sudo apt-get update
$ sudo apt-get install heaptrace
Verwenden Sie Ihren bevorzugten AUR-Helfer, um eines der beiden folgenden Pakete zu installieren:
heaptrace-git — Quellpaket (PKGBUILD)heaptrace — Binärpaket (PKGBUILD)$ trizen -S heaptrace-git
... ODER ...
$ trizen -S heaptrace
$ git clone https://github.com/Arinerron/heaptrace.git && cd heaptrace
$ make
$ sudo make install
...
$ heaptrace ./target
Sie können Argumente für heaptrace vor dem Binärnamen angeben:
Usage:
heaptrace [options...] <target> [args...]
heaptrace [options...] --attach <pid>
Options:
-p <pid>, --attach <pid>, --pid <pid>
Tells heaptrace to attach to the specified pid
instead of running the binary from the `target`
argument. Note that if you specify this argument
you do not have to specify `target`.
-b <expression>, --break=<expression>, --break-at=<expression>
Send SIGSTOP to the process when the specified
`expression` is satisfied and attach the GNU debugger
(gdb) to the process.
This argument supports complex expressions. Please
See the documentation for more information:
https://github.com/Arinerron/heaptrace/wiki/How-to-Create-Breakpoints
-B <expression>, --break-after=<expression>
Similar to `--break`. Replaces the tracer
process with gdb, but only after the heap function
returns. See the documentation for more information:
https://github.com/Arinerron/heaptrace/wiki/How-to-Create-Breakpoints
-e <name=value>, --environ=<name=value>, --environment=<name=value>
Sets a single environmental variable. Useful for
setting runtime settings for the target such as
LD_PRELOAD=./libc.so.6 without having them affect
heaptrace's runtime configuration. This option can
be used multiple times.
-s <sym_defs>, --symbols=<sym_defs>
Override the values heaptrace detects for the
malloc/calloc/free/realloc/reallocarray symbols.
Useful if heaptrace fails to automatically
identify heap functions in a stripped binary. See
the wiki for more info.
-F, --follow-fork, --follow
Tells heaptrace to detach the parent and follow
the child if the target calls fork(), vfork(), or
clone().
The default behavior is to detach the child and
only trace the parent.
-G <path>, --gdb-path <path>
Tells heaptrace to use the path to gdb specified
in `path` instead of /usr/bin/gdb (default).
-w <width>, --width=<width>, --term-width=<width>
Force a certain terminal width.
-o <file>, --output=<file>
Write the heaptrace output to `file` instead of
/dev/stderr (which is the default output path).
-v, --verbose
Prints verbose information such as line numbers in
source code given the required debugging info is
stored in the ELF.
-V, --version
Displays the current heaptrace version.
-h, --help
Shows this help menu.
heaptrace --break=3 ./my-binary ausführen. Weitere Informationen zur Verwendung dieses Arguments finden Sie in der Wiki-Dokumentation.-s/--symbol, um gestrippte Binärdateien zu debuggen, bei denen heaptrace nicht automatisch Funktionen identifizieren konnte.$NO_COLOR, um ANSI-Farbcodes aus der Ausgabe zu entfernen. Diese Option befindet sich noch in Entwicklung und wird bald in ein Argument umgewandelt.Ich helfe gerne, wenn Sie einen Fehler feststellen oder Feedback haben. Bitte besuchen Sie die GitHub Issues Seite.