Module 4 ยท Lesson 3 ยท 30 minutes

๐Ÿ•ต๏ธ What to do with scan results

You see "OpenSSH 7.4 Ubuntu". What is it? Where to look for "known vulnerabilities"? How to decide whether to "dig deeper" or "move to another target"?

๐Ÿ“– Why you need to know this

In 2021, a hacker scanned a major bank (legally โ€” it was a commissioned pentest). In the nmap output, he saw one line: port 10000, Webmin version 1.962.

He Googled "Webmin 1.962 vulnerabilities". He found a ready-made instruction: "this version has a vulnerability through which you can log in without a password". Within 3 minutes, he had full access to the server. The pentest boiled down to one line from the scan.

In the previous lesson, we learned how to run a scanner. Now you need to read its output like a detective โ€” which clues are real, and which are red herrings.

Without this lesson, scanning is a waste of time. With it, it's your main skill for the first years of pentesting.

๐Ÿ“– What is CVE

๐ŸŽฏ In a nutshell in 30 seconds

CVE = a catalog of all known vulnerabilities in software.

Imagine: for every lock brand, there's a police file: "this brand of lock has a known vulnerability, it can be opened with a coin". It's the same for software โ€” there's a huge public catalog of all known vulnerabilities.

Each vulnerability gets a number like CVE-2024-12345: year + sequential number. The catalog website is nvd.nist.gov.

Full name: Common Vulnerabilities and Exposures. You don't need to memorize it โ€” it's enough to know "CVE = a known vulnerability with a public file".

๐Ÿ“Š How dangerous is a vulnerability โ€” CVSS

Each vulnerability in the catalog has a severity rating from 0 to 10 โ€” called CVSS. The higher, the worse.

RatingLevelIn a nutshell
9.0-10.0๐Ÿ”ด Critical"House with no door โ€” anyone can walk in"
7.0-8.9๐ŸŸ  High"Lock opens with a pick in 5 minutes"
4.0-6.9๐ŸŸก Medium"Complex lock, but can be breached"
0.1-3.9๐ŸŸข Low"Theoretically possible, but few would bother"

A hacker always looks at ๐Ÿ”ด and ๐ŸŸ  first.

๐Ÿ”„ Path from scan to lead

๐ŸŽฏ In a nutshell in 30 seconds

5 steps:

  1. nmap found service + version: OpenSSH 7.4
  2. Google: "OpenSSH 7.4 CVE" โ†’ list of vulnerabilities
  3. Read description + check rating (9.0 = very dangerous)
  4. Look for a ready-made "exploitation tool" on Exploit-DB or GitHub
  5. Test on a training virtual machine (not on someone else's production server!)

๐Ÿšจ 4 "red flags" in nmap output

Let's say nmap showed this:

22/tcp   open  ssh     OpenSSH 7.4 (Ubuntu Linux)
80/tcp   open  http    Apache httpd 2.4.7 ((Ubuntu))
3306/tcp open  mysql   MySQL 5.5.40
8080/tcp open  http    Jenkins httpd 2.107

An experienced hacker immediately sees 4 problems:

๐Ÿšจ Flag 1: old versions

MySQL 5.5 โ€” from 2014. Apache 2.4.7 โ€” from 2013. This is ancient. Public vulnerabilities are guaranteed. Analogy: a 1980 house with its original wooden door.

๐Ÿšจ Flag 2: database exposed to the outside

Port 3306 (MySQL) should not be open to the internet. The database should only be visible to its own server. If it's open, a hacker will simply try to log in as root without a password. Analogy: a warehouse open to passers-by from the street.

๐Ÿšจ Flag 3: Jenkins on 8080

Jenkins is a program for developers that builds code. It contains secret keys, tokens, and access to prod servers. It's often left open without a password. An RCE (remote code execution) vulnerability is common.

๐Ÿšจ Flag 4: default passwords

Many services start with the pair admin/admin, root/root, root/123456. Owners forget to change them. Thousands of servers with such "passwords" are exposed on the internet right now.

๐Ÿ“š Where to go with the version

WebsiteWhat's thereHow to explain to mom
nvd.nist.govOfficial CVE catalog"Police file on every vulnerability"
exploit-db.comDatabase of ready-made "exploitation tools""Lock-picking tool shop with instructions"