Skip to content

Commit

Permalink
force password as str
Browse files Browse the repository at this point in the history
  • Loading branch information
AlessandroZ committed Feb 15, 2018
1 parent 0be59c2 commit 61379c6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Windows/lazagne/config/dpapi_structure.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(self, password=None, pwdhash=None):
self.umkp.addCredhistFile(self.sid, credhist)

if password:
if self.umkp.try_credential(self.sid, password):
if self.umkp.try_credential(self.sid, str(password)):
self.dpapi_ok = True
else:
print_debug('DEBUG', 'Password not correct: {password}'.format(password=password))
Expand All @@ -67,7 +67,7 @@ def check_credentials(self, passwords):
if self.umkp:
for password in passwords:
print_debug('INFO', 'Check password: {password}'.format(password=password))
if self.umkp.try_credential(self.sid, password):
if self.umkp.try_credential(self.sid, str(password)):
print_debug('INFO', 'User password found: {password}\n'.format(password=password))
self.dpapi_ok = True
return password
Expand Down

0 comments on commit 61379c6

Please sign in to comment.