mirror of
https://github.com/cisagov/snafflepy
synced 2026-09-24 18:22:23 +00:00
Merge pull request #38 from aelmosalamy/patch-1
cleanup: removed redundant any() check
This commit is contained in:
+4
-5
@@ -116,11 +116,10 @@ class SMBClient:
|
||||
|
||||
bad_statuses = [
|
||||
'LOGON_FAIL', 'PASSWORD_EXPIRED', 'LOCKED_OUT', 'SESSION_DELETED']
|
||||
if any([s in str(e) for s in bad_statuses]):
|
||||
for s in bad_statuses:
|
||||
if s in str(e):
|
||||
log.warning(
|
||||
f'{self.server}: {s}: {self.username}')
|
||||
for s in bad_statuses:
|
||||
if s in str(e):
|
||||
log.warning(
|
||||
f'{self.server}: {s}: {self.username}')
|
||||
|
||||
log.debug(f'{self.server}: Trying guest session')
|
||||
self.username = 'Guest'
|
||||
|
||||
Reference in New Issue
Block a user