Skip to content

Instantly share code, notes, and snippets.

@vinitkumar
Created August 21, 2012 20:46
Show Gist options
  • Save vinitkumar/3419295 to your computer and use it in GitHub Desktop.
Save vinitkumar/3419295 to your computer and use it in GitHub Desktop.

============================== title: How did i pulled it off

The task sound pretty simple, to find a unknown password that occurs only once in 1100 line password dump.Also each of these passwords are 30 letters long.

Here is how i went with this problems.

Here is the password dump (dump)[http://paste.ubuntu.com/115909/] First i sorted the dump and then got the uniq password and stored them in another text file. (sorted and uniq text)[http://paste.ubuntu.com/1159711]

Then here is the python code I used to find the password.

` #! /usr/bin/env python

fp = open('hack.txt','r') up = open('uniq.txt','r')

keys = up.readlines()

stuff = []

for st in fp.readlines(): stuff.append(st)

print type(stuff)

for key in keys:

if stuff.count(key) == 1:
    print key

`

That's it!!

Happy Hacking!

@elshanilaureta
Copy link

Hajgare a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment