erforschr/bruteforce-http-auth

Failure to brute force

mubix opened this issue · 2 comments

mubix commented

Not sure whats going wrong (sorry, not much of a python geek)

/bruteforce-http-auth# python3 bruteforce-http-auth.py -t https://website/ -P ../passwords.txt -U ../users.txt
[17-09-53] --------------------------
[17-09-53] ~  Bruteforce HTTP Auth  ~
[17-09-53] --------------------------
[17-09-53] 
[17-09-53] Included in bruteforce scope:
[17-09-53] 
[17-09-53] => URL: https://website/
[17-09-53]    Status code: 401
[17-09-53]    Server: Microsoft-IIS/10.0
[17-09-53]    Date: Tue, 17 Jul 2018 21:07:50 GMT
[17-09-53]    Authentication type: ntlm
[17-09-53] 
[17-09-53] Launch bruteforce on included targets [y/N] ? y
[17-09-54] 
Traceback (most recent call last):
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
  File "bruteforce-http-auth.py", line 246, in test
    if resp.status_code == 200:
Traceback (most recent call last):
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
  File "bruteforce-http-auth.py", line 246, in test
    if resp.status_code == 200:
UnboundLocalError: local variable 'resp' referenced before assignment
WorkerBruteforce => <class 'UnboundLocalError'> : local variable 'resp' referenced before assignment
Traceback (most recent call last):
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
Traceback (most recent call last):
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
Traceback (most recent call last):
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
  File "bruteforce-http-auth.py", line 246, in test
    if resp.status_code == 200:
UnboundLocalError: local variable 'resp' referenced before assignment
WorkerBruteforce => <class 'UnboundLocalError'> : local variable 'resp' referenced before assignment
  File "bruteforce-http-auth.py", line 246, in test
    if resp.status_code == 200:
UnboundLocalError: local variable 'resp' referenced before assignment
UnboundLocalError: local variable 'resp' referenced before assignment
Traceback (most recent call last):
WorkerBruteforce => <class 'UnboundLocalError'> : local variable 'resp' referenced before assignment
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
WorkerBruteforce => <class 'UnboundLocalError'> : local variable 'resp' referenced before assignment
  File "bruteforce-http-auth.py", line 246, in test
    if resp.status_code == 200:
Traceback (most recent call last):
Traceback (most recent call last):
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
  File "bruteforce-http-auth.py", line 246, in test
    if resp.status_code == 200:
  File "bruteforce-http-auth.py", line 329, in run
    test = HTTP_Auth.test(test)
  File "bruteforce-http-auth.py", line 246, in test
    if resp.status_code == 200:
UnboundLocalError: local variable 'resp' referenced before assignment
WorkerBruteforce => <class 'UnboundLocalError'> : local variable 'resp' referenced before assignment
Traceback (most recent call last):
  File "bruteforce-http-auth.py", line 329, in run

It's a typo in line 241. Replace "ntml" with "ntlm" and it will work...

Fixed by pull request 2.
Thanks to @KonnySam !