Skip to content

Instantly share code, notes, and snippets.

@mrdmnd
Created August 12, 2012 08:57
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 mrdmnd/3330742 to your computer and use it in GitHub Desktop.
Save mrdmnd/3330742 to your computer and use it in GitHub Desktop.
Quick bruteforcer. No results.
import sys
sys.path.append("./python-keepass/python")
from keepass import kpdb
byte_strings = [hex(x)[2:].rjust(2, '0').lower() for x in range(255)]
pass_template = "%s3b140a6ec5%sec"
num_tried = 0
for s1 in byte_strings:
for s2 in byte_strings:
tmp_pw = pass_template % (s1, s2)
num_tried += 1
if num_tried % 1000 == 0:
print 'Trying %s, attempt # %s' % (tmp_pw, num_tried)
try:
db = kpdb.Database("/home/ec2-user/3hzd3ob2wBBeMsmkUW1AHZH78TlgL1UMBVBL07mY.kdbx", tmp_pw)
print db
break
except IOError:
continue
~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment