Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #test.py
- import hashlib
- a = open("accounts.shh", "r")
- login1 = a.read()
- login2 = login1.split(":")
- user1 = raw_input("enter your username: ")
- passwd1 = raw_input("enter your password: ")
- md5 = hashlib.md5(passwd1).hexdigest()
- if (user1 == login2[0]):
- if (md5 == login2[1]):
- print "You are logged in."
- else:
- print "Your password is wrong."
- else:
- print "You entered wrong username."
- #accounts.ssh
- test:098f6bcd4621d373cade4e832627b4f6
Add Comment
Please, Sign In to add comment