Created
November 11, 2017 18:29
-
-
Save nxsyed/3b269e0432a7101bcc4e9b0f6f791316 to your computer and use it in GitHub Desktop.
Test password function which compares the encrypted password to the dictionary.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def test_pass(encrypted_pass, filename): | |
salt = encrypted_pass[0:2] | |
dict_list = open(filename,'r').split('\n') | |
for word in dict_list: | |
crypt_word = c.crypt(word, salt) | |
if (crypt_word == encrypted_pass): | |
print("[$] Found Password: "+word+"\n") | |
return | |
print("[-] Password Not Found.\n") | |
return |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment