Skip to content

Commit

Permalink
Improved Credentials structure
Browse files Browse the repository at this point in the history
  • Loading branch information
p0dalirius committed Jun 24, 2024
1 parent 6ac2bd0 commit 5ce5407
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions smbclientng/core/Credentials.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ class Credentials(object):
username = None
password = None
# Hashes
nt_hex = None
nt_raw = None
lm_hex = None
lm_raw = None
nt_hex = ""
nt_raw = ""
lm_hex = ""
lm_raw = ""
# Kerberos
use_kerberos = False
aesKey = None
Expand All @@ -36,10 +36,10 @@ def __init__(self, domain, username, password, hashes=None, use_kerberos=False,
self.username = username
self.password = password
# Hashes
self.nt_hex = None
self.nt_raw = None
self.lm_hex = None
self.lm_raw = None
self.nt_hex = ""
self.nt_raw = ""
self.lm_hex = ""
self.lm_raw = ""
self.set_hashes(hashes=hashes)
# Kerberos
self.use_kerberos = use_kerberos
Expand All @@ -59,10 +59,10 @@ def set_hashes(self, hashes):
hashes (str): A string containing LM and NT hashes separated by a colon.
"""

self.nt_hex = None
self.nt_raw = None
self.lm_hex = None
self.lm_raw = None
self.nt_hex = ""
self.nt_raw = ""
self.lm_hex = ""
self.lm_raw = ""

lmhash, nthash = None, None
if hashes is not None:
Expand Down

0 comments on commit 5ce5407

Please sign in to comment.