Skip to content

Instantly share code, notes, and snippets.

@kmcallister
Created May 27, 2012 03:04
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save kmcallister/2799304 to your computer and use it in GitHub Desktop.
Save kmcallister/2799304 to your computer and use it in GitHub Desktop.
dump vdso
#!/usr/bin/env python
from ctypes import *
for ln in open('/proc/self/maps'):
if "[vdso]" in ln:
start, end = [int(x,16) for x in ln.split()[0].split('-')]
CDLL("libc.so.6").write(1, c_void_p(start), end-start)
break
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment