Practice Example of Scanning and Enumeration

Practice Example of Scanning and Enumeration

You are a Junior Penetration Tester at CyberShield Security, a consulting firm specializing in internal network assessments. Your team has been asked to assess the internal security posture of a client by identifying exposed services and misconfigurations in their development staging environment. You've been assigned a virtual lab system, Metasploitable 2, which mirrors their older infrastructure.

Your goal is to conduct scanning and enumeration using industry-standard tools, make decisions based on your findings, and identify areas of exposure that could be exploited in a future phase of the engagement.

Task 1: Perform Basic Network Reconnaissance

Objective: Identify the live host and determine which services it exposes.

You begin with a basic subnet scan using Nmap to discover live hosts:

nmap -sn 10.0.2.4/24

Article content
nmap -sn output

This reveals that the target host (Metasploitable 2) is up at 10.0.2.4. Next, you perform a more detailed scan to gather service and version information:

nmap -sV -A 10.0.2.4

Article content
nmap -sV -A 10.0.2.4 output

Why this matters:

-sV identifies version numbers for exposed services, which can be mapped to known vulnerabilities.

-A enables OS detection and script scanning, providing deeper context.

Strategic Reflection: In a monitored environment, this aggressive scan could trigger alerts. In a red team engagement, you might instead use -sS -T2 for a stealthy SYN scan and trade speed for stealth.

Task 2: Enumerate Services for Deeper Insight

Objective: Probe services to uncover misconfigurations, banners, and access levels.

You select two services to focus on: FTP and SMB.

FTP Enumeration

You run:

nmap -p 21 --script ftp-anon 10.0.2.4

You also connect manually:

ftp 10.0.2.4

Article content
output


SMB Enumeration

You run:

nmap --script=smb-enum-shares,smb-os-discovery -p 139,445 10.0.2.4

Article content
output


Then follow up with:

enum4linux -a 10.0.2.4

Article content
output

Task 3: Analyze Results and Assess the Attack Surface

Objective: Use enumeration data to evaluate which services pose the most risk.

From your findings:

The system runs multiple outdated services with known vulnerabilities.

Anonymous access is enabled on both FTP and SMB.

Database services (MySQL, PostgreSQL) are exposed to the network.

You prioritize SMB as the highest-risk target for a follow-up exploitation phase:

It allows guest access.

It runs an old, vulnerable Samba version.

Misconfigurations align with real-world attacks.

You summarize the system's attack surface as:

Broad and risky, with unauthenticated access, outdated software, and open administrative ports.

Real-World Thinking: In a live client engagement, this level of exposure would warrant immediate remediation. Even if exploitation isn't authorized yet, enumeration alone has revealed serious risk.

Takeaways

Scan types have tradeoffs — be strategic in their use based on environment sensitivity.

Enumeration is about depth, not just listing services — extract access levels, configurations, and vulnerabilities.

Misconfigurations matter as much as CVEs — anonymous access, guest shares, or weak protocols expose systems in different ways.

Article content


To view or add a comment, sign in

More articles by Ernest Osindo

  • Web Log Analysis: How I Detected and Traced a Bank Breach Step by Step

    📋 THE TASK Web Log Investigation TryBankMe, a small online banking platform, has suffered a breach. Attackers broke in…

  • Adding Data to Splunk

    Splunk can ingest any data. According to the Splunk documentation, when data is added to Splunk, the data is processed…

  • Malicious Email Analysis

    True Positive Report: Email Analysis A Sales Executive at Greenholt PLC received an email that he didn't expect to…

Others also viewed

Explore content categories