Skip to content

Commit 10e7c62

Browse files
committed
Allow anonymous auth with asreproast and kerb/hash auth
1 parent e2e70a7 commit 10e7c62

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

nxc/protocols/ldap.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ def kerberos_login(self, domain, username, password="", ntlm_hash="", aesKey="",
364364
if nthash:
365365
self.nthash = nthash
366366

367-
if self.password == "" and self.args.asreproast:
367+
if self.username and self.password == "" and self.args.asreproast:
368368
hash_tgt = KerberosAttacks(self).get_tgt_asroast(self.username)
369369
if hash_tgt:
370370
self.logger.highlight(f"{hash_tgt}")
@@ -574,7 +574,7 @@ def hash_login(self, domain, username, ntlm_hash):
574574
self.username = username
575575
self.domain = domain
576576

577-
if self.hash == "" and self.args.asreproast:
577+
if self.username and self.hash == "" and self.args.asreproast:
578578
hash_tgt = KerberosAttacks(self).get_tgt_asroast(self.username)
579579
if hash_tgt:
580580
self.logger.highlight(f"{hash_tgt}")

0 commit comments

Comments
 (0)