boot767 notes · 24 posts

Every Shell Leaves a Trace

I keep what I learn about offensive security here: my notes from CTFs, certifications and university, plus the walkthroughs I write when a box is worth sharing. It's organized the way I work a box. Recon first, then a foothold, then privilege escalation, then the rest of the network.

latest transmission · 2026-11-19Collection of OSINT Tools and Resources
boot767 notes · 24 posts

Every Shell Leaves a Trace

I keep what I learn about offensive security here: my notes from CTFs, certifications and university, plus the walkthroughs I write when a box is worth sharing. It's organized the way I work a box. Recon first, then a foothold, then privilege escalation, then the rest of the network.

latest transmission · 2026-11-19Collection of OSINT Tools and Resources

Brute Force

Alongside packet captures, MITM attacks, and the defences against them (TLS and SSH), this room covers a third class of attack: going after passwords.

Many protocols require authentication, which is proving who you claim to be. With a protocol such as POP3, the server should not hand over the mailbox before our identity is verified. The POP3 example from the Protocols and Servers room is repeated below. Here we are identified as the user frank, and the server authenticates us because we supply the correct password. The password is one way to handle authentication.

POP3 session over Telnet

pentester@TryHackMe$ telnet MACHINE_IP 110
Trying MACHINE_IP...
Connected to MACHINE_IP.
Escape character is '^]'.
+OK MACHINE_IP Mail Server POP3 Wed, 15 Sep 2021 11:05:34 +0300 
USER frank
+OK frank
PASS D2xc9CgD
+OK 1 messages (179) octets
STAT
+OK 1 179
LIST
+OK 1 messages (179) octets
1 179
.
RETR 1
+OK
From: Mail Server 
To: Frank 
subject: Sending email with Telnet
Hello Frank,
I am just writing to say hi!
.
QUIT
+OK MACHINE_IP closing connection
Connection closed by foreign host.

Authentication can be achieved through one of the following, or a combination of two:

  1. Something you know, such as a password or PIN code.
  2. Something you have, such as a SIM card, RFID card, or USB dongle.
  3. Something you are, such as a fingerprint or iris.

This task focuses on attacks against passwords, i.e. something the target knows. Revisiting the earlier servers running Telnet, SSH, POP3, and IMAP, every one of them needed a password for access. Based on the 150 million usernames and passwords leaked in the 2013 Adobe breach, the top ten passwords were:

Only two of these relate to Adobe and its products; the rest are generic. You might expect this to have changed over the past decade, but 123456, 1234567, 12345678, and 123456789 are still common choices. Others still haven't realized that qwerty is not a secret, yet many use it as their password.

Types of password attack

Attacks against passwords are usually carried out by:

  1. Password Guessing: Guessing a password requires some knowledge of the target, such as their pet's name and birth year.
  2. Dictionary Attack: This approach expands on password guessing and attempts to include all valid words in a dictionary or a wordlist.
  3. Brute Force Attack: The most exhaustive and time-consuming attack, where an attacker can go as far as trying all possible character combinations. The work grows fast (exponential growth with the number of characters).

Dictionary attacks with Hydra

Over time, attackers have compiled list after list of leaked passwords from data breaches. One example is RockYou's list of breached passwords, which is on the AttackBox at /usr/share/wordlists/rockyou.txt. The choice of wordlist should depend on your knowledge of the target. A French user might pick a French word rather than an English one, so a French wordlist would be more promising there.

To try common passwords or wordlist entries automatically, we use THC Hydra. Hydra supports many protocols, including FTP, POP3, IMAP, SMTP, SSH, and all methods related to HTTP. The general syntax is:

hydra -l username -P wordlist.txt server service

Some concrete examples:

Optional arguments

Once the password is found, you can issue CTRL-C to end the process. In TryHackMe tasks, any attack is expected to finish in less than five minutes; in real-life scenarios it would usually take longer. The verbosity and debugging options are handy when you want Hydra to keep you updated on its progress.

Mitigation

Attacks against login systems can be carried out efficiently with a tool like THC Hydra combined with a suitable wordlist. Mitigation can be sophisticated and depends on the target system. A few approaches:

Combining several of the above is an excellent way to protect against password attacks.