Advertisement
Stosswalkinator

Password Locker

Feb 5th, 2017
250
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.59 KB | None | 0 0
  1. #! python3
  2. # pw.py - An insecure password locker program.
  3.  
  4. PASSWORDS = {'email': 'F7minlBDDuvMJuxESSKHFhTxFtjVB6',
  5.              'blog': 'VmALvQyKAxiVH5G8v01if1MLZF3sdt',
  6.              'luggage': '12345'}
  7.  
  8. import sys, pyperclip
  9. if len(sys.argv) < 2:
  10.     print('Usage: python pw.py [account] - copy account password')
  11.     sys.exit()
  12.  
  13. account = sys.argv[1] # first command line arg is the account name
  14.  
  15. if account in PASSWORDS:
  16.     pyperclip.copy(PASSWORDS[account])
  17.     print('Password for ' + account + ' copied to clipboard.')
  18. else:
  19.     print('There is no account named ' + account)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement