zardus / preeny

Some helpful preload libraries for pwning stuff.
BSD 2-Clause "Simplified" License
1.57k stars 170 forks source link

decookie.so: Dump stack cookie on startup #41

Closed ZetaTwo closed 6 years ago

ZetaTwo commented 6 years ago

A new module to dump the generated stack cookie on startup. Good for finding offsets in memory leaks.

Based on this article: https://www.elttam.com.au/blog/playing-with-canaries/ Based on this code: https://github.com/elttam/canary-fun/blob/master/read_canary.c

 PREENY_INFO=1 LD_PRELOAD=./x86_64-linux-gnu/decookie.so ./tests/hello 
--- Found canary: 0x2ae8dc00
Hello world!
zardus commented 6 years ago

Awesome stuff. Could you also add it to the Makefile?

zardus commented 6 years ago

Haha, nevermind, I forgot that the Makefile finds them automatically :-)