Network Discovery - Scan-ta Clause

Day 7

Discover how to scan network ports and uncover what is hidden behind them.

Discover Network Services

Overview


Room URL: https://tryhackme.com/room/networkservices-aoc2025-jnsoqbxgky
Difficulty: Easy
Category: Network Scanning
Date Completed: 12/7/2025

Objectives


Table of Contents

Introduction
Walk Through
Lessons Learned
Resources


Introduction

After regaining knowledge of the tbfc-devqa01 QA server's IP address, TBFC's security team launches a counterattack to reclaim the compromised system from HopSec's grasp. The server greets you with a defaced website proclaiming "Pwned by HopSec," but beneath this digital taunt lies a vulnerability: exposed services running on non-standard ports. Your mission is to systematically discover these hidden services through multi-layered port scanning, extract three critical keys scattered across different protocols (FTP, custom TCP, and DNS), and use them to access a secret admin console. Once inside, you'll uncover additional internal services and retrieve the final flag from the MySQL database, exposing the full extent of the breach and paving the way for complete system recovery.

Key Information


Walk Through

  1. Start the target machine and connect to the VPN
  2. What evil message do you see on top of the website?
    1. IP 10.81.144.241
      1. In web-browser go to http://10.81.144.241
    2. Top Banner says TBF QA Pwned by HopSec
  3. What is the first key part found on the FTP server?
    1. Run a simple scan on 10.81.144.241 using nmap
    2. nmap 10.81.144.241
      1. Results show 22/tcp open and 80/tcp open
      2. Pasted image 20251207142408.png
    3. nmap -p- --script=banner 10.81.144.241
      1. -p- scans all ports
      2. --script=banner shows what is likely behind the ports
      3. This san revealed two extra ports
        1. 21212/tcp open (vsFTPd 3.0.5)
        2. 25251/tcp open (TBFC maintd v0.2x0A
        3. Pasted image 20251207143126.png
    4. Opened FTP connection in using ftp 10.81.144.241 21212
      1. username anonymous
      2. ls to list files
      3. get tbfc qa_key1 to download file
      4. exit
      5. cat tbfc_qa_key1 to view key
      6. Pasted image 20251207144408.png
  4. What is the second key part found in the TBFC app?
    1. Use netcat to get more information from port 25251
    2. nc -v 10.81.144.241 25251
      1. Pasted image 20251207144836.png
    3. Use HELP to view commands
      1. Pasted image 20251207144916.png
    4. Use GET KEY to view key
      1. Pasted image 20251207144948.png
  5. What is the third key part found in the DNS records? 1. Use nmap to scan UDP ports instead of TCP 2. nmap -sU 10.81.144.241 1. Pasted image 20251207150711.png 3. Use dig to see records on DNS server 1. dig @10.81.144.241 TXT key3.tbfc.local 1. Pasted image 20251207151127.png
  6. Which port was the MySQL database running on?
    1. Log into the admin portal at http://10.81.144.241
    2. use e3ster_15_th3_n3w_xm45 to access portal
      1. Pasted image 20251207151548.png
    3. Can use histroy to see the terminal history
      1. That reveals ports 56123 and 3306 used in mysql commands
    4. Can also use ss -tulnp to see open listening connections
      1. This reveals port 3306 is active and listening on the localhost
        1. Pasted image 20251207151953.png
    5. Finally, what's the flag you found in the database?
      1. The history reveals a database of tbfcqa01
        1. Pasted image 20251207152151.png
      2. mysql -D tbfcqa01 -e "show tables;" to view tables
      3. mysql -D tbfcqa01 -e "select * from flags;"
        1. Screenshot 2025-12-07 at 3.26.20 PM.png

Lessons Learned


Resources

TryHackMe
Dig CheatSheet
MySql CheatSheet
Nmap CheatSheet
NetCat CheatSheet