Skip to content

Commit

Permalink
py2 fix and small cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
dirkjanm committed Sep 24, 2020
1 parent a753712 commit 63eb977
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions impacket/examples/ntlmrelayx/clients/dcsyncclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,11 +301,6 @@ def sendAuth(self, authenticateMessageBlob, serverChallenge=None):
LOG.error('Could not dump administrator (renamed?)')

return None, STATUS_SUCCESS
# elif 'rpc_s_access_denied' in str(e):
# return None, STATUS_ACCESS_DENIED
# else:
# LOG.info("Unexpected rpc code received from %s: %s" % (self.stringbinding, str(e)))
# return None, STATUS_ACCESS_DENIED
except Exception as e:
traceback.print_exc()
finally:
Expand Down Expand Up @@ -352,9 +347,9 @@ def netlogonSessionKey(self, challenge, authenticateMessageBlob):
if ex.get_error_code() == 0xc0000022:
continue
else:
print(f'Unexpected error code from DC: {ex.get_error_code()}.')
LOG.error('Unexpected error code from DC: %d.', ex.get_error_code())
except BaseException as ex:
print(f'Unexpected error: {ex}.')
LOG.error('Unexpected error: %s', str(ex))
LOG.info('Netlogon Auth OK, successfully bypassed autentication using Zerologon after %d attempts!', attempt)
break
else:
Expand Down

0 comments on commit 63eb977

Please sign in to comment.