Security operations

Penetration Testing: What It Is, Types, Process and Cost

A vulnerability scan lists what might be wrong. A penetration test proves what an attacker can actually do with it. Here is how a real test works, what it costs, and how to read the report.

Cysoro Security TeamPublished · 9 min read
$ nmap -sV target.local443/tcp open https8080/tcp open http-proxy3 findings confirmed _ SECURITY OPERATIONS Penetrationtesting Prove it before an attacker does.
Quick answer

Penetration testing is an authorized, simulated cyberattack on a system, network or application, carried out to find and exploit vulnerabilities before real attackers do. A tester follows a documented methodology, tries to gain access within agreed rules, and reports each confirmed finding with evidence and a fix, so the organization can repair the real risks first.

Key takeaways

  • A penetration test proves exploitability with evidence; a vulnerability scan only lists possible weaknesses.
  • Every legitimate test starts with written authorization, a defined scope and rules of engagement.
  • The report matters more than the hacking: prioritize findings by proven business impact, then retest the fixes.

A scanner can tell you that a door is unlocked. It cannot tell you what an attacker does after walking through it. That is the job of penetration testing: a controlled, authorized attack that proves which weaknesses matter and which are only theoretical.

What is penetration testing?

Penetration testing, often called pen testing, is an authorized simulated attack on a system, network or application. A skilled tester tries to find and exploit vulnerabilities the way a real attacker would, then reports what worked.

The key word is authorized. The tester works under a signed agreement that defines exactly what is in scope, what is off limits, and what happens if something breaks. Without that agreement, the same actions would be a crime.

The output is evidence, not a list of guesses. A good finding shows the steps taken, the data reached, and the business impact — for example, that an attacker could read customer records, not just that a server was out of date. That evidence is what lets you fix the right things first.

Penetration testing vs vulnerability scanning: what's the difference?

A vulnerability scan is automated and broad: it checks systems against a database of known weaknesses and reports matches. A penetration test is human-led and deep: a tester verifies those matches by exploiting them.

Think of a scan as a smoke alarm and a test as a fire drill. The alarm tells you something may be wrong; the drill shows whether people can actually get out. Both have a place, and a test usually starts with scanning, then goes further.

Vulnerability scanPenetration test
Who runs itAutomated tool, often on a scheduleHuman tester, sometimes with tools
What it provesA weakness may existA weakness can be exploited, with evidence
False positivesCommon — needs triageLow — findings are confirmed by exploitation
CoverageBroad, shallowNarrower, much deeper
Typical frequencyWeekly or monthlyAt least annually, plus after big changes
Best forContinuous hygiene, patch trackingReal risk, compliance, major releases

A scan that reports 500 issues does not mean you have 500 real risks. A test that confirms five exploitable paths to your customer database tells you far more. Use scans to stay tidy between tests, and tests to check whether the tidy systems would actually hold.

What are the main types of penetration testing?

Tests are named by what they target. Most organizations need more than one type over time, because a web application, a network and a workforce fail in different ways.

Web application testing

Tests a website or web application for flaws such as injection, broken access control, insecure authentication and misconfigured APIs. Testers usually follow the OWASP Web Security Testing Guide and check findings against the OWASP Top 10.

Network testing

Tests internal and external networks: open ports, exposed services, weak segmentation, and whether an attacker who reaches one workstation can move to servers and domain controllers.

Cloud testing

Tests cloud configuration and identity: over-permissive roles, public storage buckets, exposed management interfaces and insecure CI/CD pipelines. Cloud providers have their own testing policies, so the tester must stay inside them.

Social engineering testing

Tests people and process, usually with phishing emails or phone calls, to see whether staff hand over credentials or approve fraudulent requests. This is where many tests succeed first, because people are often the weakest link. See our guide to spear phishing for the attack this simulates.

Wireless testing

Tests Wi-Fi networks for weak encryption, rogue access points and credential capture. It matters most for offices, warehouses and any site where visitors share the network. Our guide to securing your Wi-Fi covers the basic defenses a test will check.

Physical testing

Tests whether someone can walk into a building, tailgate through a door, or plug a device into a network port. It is usually reserved for larger organizations with sensitive premises.

What is black box, white box and grey box testing?

These terms describe how much the tester knows before they start. The choice changes what the test can find and how realistic it is.

Black box testing gives the tester no inside knowledge, like an external attacker starting from the internet. It is the most realistic for outside threats, but it can miss deep flaws that need insider context.

White box testing gives the tester full access: source code, architecture diagrams, credentials and configuration. It finds the most issues, but it is less like a real outside attack. Grey box testing sits in between, for example with a standard user account, and is the most common choice for web applications.

Ask your provider which approach they used and why. A report that never says which box it was is missing basic context.

How does a penetration test work?

Most tests follow the same lifecycle, whether the framework is PTES, with seven phases, or NIST SP 800-115, with four. The names differ; the work is the same.

How a penetration test runs1Scopetargets, rules,authorization2Reconmap the attacksurface3Scanfind possibleweaknesses4Exploitprove what isreally exploitable5Reportevidence, risk,fixes6Retestconfirm thefixes workedNIST SP 800-115 groups this into planning, discovery, attack and reporting.
The standard test lifecycle, from signed scope to confirmed fixes. Illustration by Cysoro.

1. Scoping and authorization

You agree the targets, the test windows, the forbidden actions (such as denial-of-service attacks or deleting data), and the emergency contacts. This is written into the rules of engagement and signed before anything starts.

2. Reconnaissance

The tester maps the target from public sources and from scanning: domains, IP ranges, open ports, services, technologies and exposed credentials. This is where most of the attack surface is found.

3. Exploitation and post-exploitation

The tester tries to exploit the weaknesses found, escalate privileges, and move laterally — for example, from a web flaw to a database, or from one workstation to a domain controller. Each success is documented with screenshots or logs.

4. Reporting and retesting

Findings are written up with severity, evidence and a recommended fix. After your team repairs them, the tester retests the critical and high findings to confirm the fix actually works.

Which frameworks do penetration testers follow?

A credible tester names their methodology, because it makes the test repeatable and the coverage checkable. The main frameworks cover different parts of the job, and mature programs combine more than one.

NIST SP 800-115 is the US government guide to security testing, with four phases: planning, discovery, attack and reporting. It also stresses that reporting runs throughout the test, not only at the end. The Penetration Testing Execution Standard (PTES) is the practitioner standard, with seven phases from pre-engagement to reporting.

For web applications, the OWASP Web Security Testing Guide supplies the test cases, and the OWASP Top 10 lists the most common risks. For threat-informed testing, MITRE ATT&CK maps real attacker tactics and techniques, so a test can be judged against how real groups actually behave. NIST SP 800-115 is the reference to read first if you are buying a test and want to know what good looks like.

FrameworkWhat it coversBest for
PTESFull engagement lifecycle, 7 phasesStructured network and application tests
NIST SP 800-115Planning, discovery, attack, reportingRegulated and federal environments
OWASP WSTGWeb and API test casesWeb application testing
MITRE ATT&CKReal attacker tactics and techniquesThreat-informed and red-team testing
OSSTMMMeasurable security across channelsBroad assessments including people and facilities

How is penetration testing different from red teaming?

Penetration testing has a defined scope and a goal: find and prove vulnerabilities in a specific system. Red teaming has a broader goal: test the whole organization, including its detection and response, against a realistic adversary campaign.

A red team may use phishing, physical entry, and long-term persistence, and it often works without telling the defenders in advance. A penetration test is usually narrower, shorter, and more transparent. If you have never had a penetration test, start there — red teaming is the next step, not the first one.

Both are different from a vulnerability assessment, which is essentially a scan plus a report, with no exploitation. If a vendor sells you a scan and calls it a penetration test, you are paying test prices for scan results.

How much does penetration testing cost?

There is no standard price, because cost depends on scope: the number of targets, the type of test, the tester experience, and the reporting depth. A small, focused web application test costs far less than a multi-week network, cloud and social engineering program.

Get at least three written quotes for the same scope, and compare what each includes: the number of test days, the methodology, the report format, and whether retesting is included. The cheapest quote is often the one with the fewest test days and no retest.

Budget for the fixes as well as the test. A test that finds ten critical issues you cannot afford to repair is less useful than a smaller test whose findings you can actually fix and retest.

How to read a penetration test reportStart with the executive summaryBusiness risk in plain language, not jargonCheck every finding has evidenceSteps, screenshots or logs — not just a claimSort by proven impact, not countOne path to customer data beats 50 low issuesLook for the attack chainHow small flaws combined into real accessFix critical and high firstThen confirm with a retest, not a promiseFeed the rest into your planMedium and low findings still need owners
A good report is a repair plan, not a trophy. Illustration by Cysoro.

How do you choose a penetration testing provider?

Choose on methodology, people and reporting — not on a brand name or a low price. Ask for a sample report with client details removed, and read it before you sign anything.

  • Methodology: which framework do they follow, and how do they map findings to it?
  • People: who will actually do the testing, and what certifications do they hold, such as OSCP, GPEN or CREST?
  • Scope honesty: do they push back on a scope that is too small, or just accept it?
  • Report quality: is the sample report clear, evidence-based and written for both executives and engineers?
  • Retesting: is a retest of fixed findings included, and for how long after the report?
  • Insurance and references: do they carry professional indemnity insurance, and can they share references in your sector?

Be wary of providers who promise a fixed number of findings, who will not name the testers, or whose sample report is mostly scanner output. IBM compares the main methodologies you can use to judge whether a provider's approach is sound.

How do you prepare for a penetration test?

Good preparation makes the test cheaper and more useful. Tell the tester what matters most, give them the access they need, and make sure someone is available to answer questions during the test window.

  1. Define the crown jewels: customer data, payment systems, admin panels, source code. The tester should aim at these.
  2. Clean up the basics first: run your own scans, patch what you can, and check your public website with the free security headers checker.
  3. Check your certificates too: run the free SSL checker on your main domains before the test starts.
  4. Agree the emergency plan: who the tester calls if a system goes down, and how they stop safely.
  5. Warn your defenders: decide in advance whether your security team knows the test is happening, and tell your hosting or cloud provider if their rules require it.
  6. Freeze big changes: do not deploy a new version mid-test, or the results will not match what is live.

After the test, do not file the report away. Assign every finding an owner and a deadline, track the fixes, and schedule the retest. Our small business cybersecurity checklist is a useful place to record the follow-up actions alongside your other controls.

The bottom line

Penetration testing turns a vague worry — are we secure? — into a specific answer with evidence. It shows which weaknesses an attacker can actually use, in what order, and what they would reach.

Start with a clear scope, a named methodology, and a provider whose sample report you have actually read. Then fix what the test proves, retest the fixes, and test again after your next major change. You can begin the preparation today with the free DNS lookup to see what your organization exposes to the internet.

Frequently asked questions

What is penetration testing in simple terms?

Penetration testing is hiring a skilled professional to try to break into your systems, with your permission, before a criminal does. They use the same techniques as real attackers, but they stop at the agreed limits and tell you exactly how they got in and how to fix it.

What is the difference between penetration testing and vulnerability scanning?

A vulnerability scan automatically checks for known weaknesses and lists what it finds. A penetration test goes further: a human tester tries to exploit those weaknesses, chain them together, and prove the real impact, such as reaching customer data. Scans are broad and fast; tests are deep and evidence-based.

How often should you do penetration testing?

Most organizations test at least once a year, and again after a major change such as a new application, a cloud migration, a merger or a serious incident. Regulated industries often test more often, and standards such as PCI DSS require testing at least annually and after significant changes.

How long does a penetration test take?

A focused web application test often takes one to three weeks, while a full network and application program can take several weeks. The scoping, testing and reporting phases all take time, and a rushed test usually means shallow coverage rather than a faster result.

Is penetration testing legal?

Yes, when it is authorized in writing by the system owner, with a defined scope and rules of engagement. Testing without permission is illegal in most countries, even with good intentions, so a signed agreement must come before any testing starts.

What is the difference between black box, white box and grey box testing?

In black box testing the tester starts with no inside knowledge, like an outside attacker. In white box testing they get full access to source code, credentials and architecture. Grey box testing sits between the two, with limited knowledge such as a standard user account.

Do small businesses need penetration testing?

Yes, if they hold customer data, take payments, or run a web application that attackers can reach. A small business does not need the largest test; a focused test on its public website and its most sensitive internal systems usually gives the best return.

What happens after a penetration test?

You get a report with confirmed findings, evidence, risk ratings and fixes. Your team repairs the issues in priority order, and the tester retests the critical and high findings to confirm they are actually fixed. The findings then feed into your wider security plan.

Sources

  1. NIST — SP 800-115, Technical Guide to Information Security Testing and Assessment
  2. IBM — Top Penetration Testing Methodologies
  3. Indusface — Complete Guide to Penetration Testing Methodology
  4. DeepStrike — Penetration Testing Methodology: Steps and Frameworks
  5. Stingrai — Penetration Testing Methodology 2026: PTES, NIST and OWASP
Written & fact-checked byCysoro Security Team

The engineers and analysts who build Cysoro's domain scanner, email-authentication checks and free security tools. We test what we write about every day — SPF, DKIM, DMARC, certificates, look-alike domains and phishing — and check each guide against the relevant standards, government guidance and vendor documentation.

  • Email authentication
  • Phishing & BEC
  • Domain & DNS security
  • Small-business security

Checked against NIST SP 800-115, the Penetration Testing Execution Standard, OWASP testing guidance and MITRE ATT&CK.

How we write and fact-check →

Free tools for this topic

No account needed.

See where your domain stands

Free for up to 3 domains. No card, no installs.

Start free