Skip to content

Instantly share code, notes, and snippets.

@withzombies
Last active June 3, 2016 15:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save withzombies/8c09fbd22657ebbc63bd1a921d1f9547 to your computer and use it in GitHub Desktop.
Save withzombies/8c09fbd22657ebbc63bd1a921d1f9547 to your computer and use it in GitHub Desktop.
buffer_frame = main.get_parameter_at(bv.arch, read_buf.address, None, 0)
# The canary is between the buffer and the saved stack registers
buffer_size = (buffer_frame.offset - canary_frame.offset) * -1
print "Buffer Size: {0} 0x{0:x}".format(buffer_size)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment