#Why this matters
Organizations deploy firewalls and automated scanners, yet attackers still chain small misconfigurations into full compromises. A penetration test (pentest) evaluates whether defences hold under realistic pressure and gives defenders clear evidence to fix weaknesses before real adversaries exploit them.
#Authorization, Rules of Engagement, and testing models
Every engagement starts with written approval and a Rules of Engagement (RoE) document defining:
- In-scope and out-of-scope assets: Exact IP ranges (
10.10.10.0/24), domains (portal.example.test), and excluded third-party systems. - Testing windows and restrictions: Approved hours, rate limits, and bans on denial-of-service or destructive actions.
- Emergency contacts and data handling: Escalation contacts for active breaches and rules for encrypting and deleting sensitive evidence after delivery.
# Example Rules of Engagement scope excerpt (lab engagement)
engagement: CyberSamSU-Internal-2026-01
authorized_targets:
- 10.10.10.0/24
- portal.example.test
excluded_targets:
- 10.10.10.1 # Core gateway (out of scope)
prohibited_actions:
- denial_of_service
- destructive_payloads
emergency_contact: soc-lead@example.test- Finds and actively exploits weaknesses to prove impact
- High depth showing real attack chains
- Takes weeks and costs more
- Delivers PoC steps and impact analysis
- Identifies potential weaknesses without exploitation
- Medium depth with broad scan coverage
- Takes days and costs less
- Delivers a prioritized findings list
Testers operate under one of three knowledge models:
- Black Box: Zero prior information beyond a domain or IP; simulates an outsider closely but takes longer.
- White Box: Full information (source code, architecture, credentials), enabling the deepest vulnerability discovery.
- Gray Box: Partial information (such as a user account or API docs), balancing realism and efficiency.
#The five-phase PTES methodology
The Penetration Testing Execution Standard (PTES) structures technical testing into five stages:
- ReconGather OSINT, domains, and exposed assets
- ScanningEnumerate live hosts, ports, and services (Nmap, Nessus)
- AccessSafely exploit authorized findings to prove risk
- Post-ExploitAssess privilege escalation and lateral movement impact
- ReportDocument evidence, CVSS risk, and remediation steps
- Recon (OSINT): Collect public DNS records, subdomains, and technology stacks within scope.
- Scanning: Map open ports and versions using Nmap or vulnerability scanners like Nessus.
- Access (Exploitation): Safely confirm exploitability to prove real risk rather than reporting raw scanner alerts.
- Post-Exploit (Privilege Escalation): Within strict RoE limits, evaluate privilege escalation or lateral movement impact without damaging systems or exfiltrating real user data.
- Report: Deliver actionable remediation guidance. Deploying patches is the defending organization's responsibility, not a PTES testing phase.
#Core assessment tools in authorized labs
- Nmap + NSE: Identifies service versions (
-sV) and runs default Nmap Scripting Engine scripts (-sC). - Burp Suite: Web testing workbench with Proxy (intercepting HTTP traffic), Repeater (manually editing and resending individual requests), Intruder (automated fuzzing), and Decoder (encoding/decoding).
- Specialized tools:
gobuster(directory discovery),wireshark(packet analysis),sqlmap(authorized SQLi verification),hydra/hashcat(authorized credential audits),bloodhound(Active Directory paths), and Metasploit strictly inside authorized lab scopes.
$ nmap -sV -sC lab.local
PORT STATE SERVICE VERSION
22/tcp open ssh OpenSSH 9.2p1 Debian
80/tcp open http nginx 1.24.0
443/tcp open https nginx 1.24.0#Reporting, CVSS risk tiers, and bug bounty ethics
A professional pentest report serves both management and engineers across five sections:
- Executive Summary: Non-technical overview of overall risk and business impact for management.
- Scope and Methodology: Tested assets, dates, exclusions, and methods used.
- Vulnerabilities Found: Each finding with CVSS score, impact, reproducible PoC steps, and screenshots.
- Recommendations and Remediation: Concrete fixes prioritized by risk.
- Appendices: Raw logs, scan tables, and supporting data.
| CVSS Score | Risk Tier | Typical Remediation Target |
|---|---|---|
| 9.0 - 10.0 | Critical | Fix immediately |
| 7.0 - 8.9 | High | Fix quickly |
| 4.0 - 6.9 | Medium | Next sprint |
| 0.1 - 3.9 | Low | Planned maintenance |
Outside formal contracts, bug bounty programs (HackerOne, Bugcrowd, Intigriti) grant legal safe harbor only for assets explicitly listed in each program's scope policy.
#Defending and common mistakes
- Skipping written authorization: Verbal permission or using a VPN never legalizes unauthorized testing.
- Confusing scanner output with a pentest: Raw Nessus or Nmap dumps contain false positives and miss business-logic flaws.
- Omitting the Executive Summary: Leadership needs a non-technical risk summary to fund Critical fixes.
- Forgetting post-test cleanup: Always remove test accounts and proof files after the engagement.
#Summary
- Written authorization and signed Rules of Engagement (RoE) are mandatory before any active testing begins.
- A penetration test actively exploits weaknesses to prove impact, unlike a vulnerability assessment; Black, Gray, and White Box models trade off realism against depth.
- The five-phase PTES lifecycle (Recon, Scanning, Access, Post-Exploit, Report) guides authorized testing end to end.
- Strong reports pair a management Executive Summary with reproducible findings prioritized by CVSS tiers (Critical 9.0-10.0, High 7.0-8.9, Medium 4.0-6.9, Low 0.1-3.9).