Black-box vs grey-box vs white-box testing: which to buy

Black-box tests start with no information, grey-box tests with partial details and white-box tests with full details of the network and applications. This page shows what each finds, misses, delivers and costs, and when to combine them.

On this page

Black-box vs grey-box vs white-box testing: which one to buy first

Black-box testing starts with no information, grey-box testing starts with partial details, and white-box testing starts with full details of the network and applications. That starting point sets how much of the tester's time goes to discovery, which weaknesses they can reach, and how far the report can speak to your environment. Choose black-box when the question is what an outsider with no inside knowledge could reach, such as testing your external perimeter or checking whether your monitoring team notices reconnaissance. Choose grey-box when you want attacker-level depth at a more controlled cost, for example by giving the tester a standard user account and an architecture diagram. Choose white-box when you need the deepest coverage of a specific system, such as a review of a payment flow with its source code and configuration in hand.

For PCI DSS scope, the Penetration Testing Guidance from PCI SSC says PCI DSS tests are typically white-box or grey-box because those levels give more accurate and comprehensive results. The same guidance notes that a black-box assessment may require more time, money and resources for its deliverables to meet PCI DSS requirements, so it is rarely the cheapest route to a compliant result. Many buyers combine levels: a black-box external test to see what an attacker finds first, followed by a grey-box authenticated test of the same systems. Ask each bidder which access level they propose, what information you will provide, and how that choice changes the hours in their quote.

The label does not guarantee depth. A grey-box test with a narrow scope and an inexperienced tester can produce less evidence than a black-box test run by a strong team against a wider perimeter. Before you sign, confirm in writing the systems and accounts in scope, the rules of engagement, the testing windows and how retesting after fixes is priced. Ask who will do the work and what they have done in similar environments. PCI SSC lists credentials such as OSCP and CREST certifications as indications of skill, while stating that it does not validate them and that certifications alone do not establish experience. Treat the access level as one decision among several, and let the scope and the named testers decide the depth you actually get.

How black-box, grey-box and white-box tests compare side by side

This table compares black-box, grey-box and white-box tests on the factors that drive what you buy and what evidence you receive. Read each row against the scope and rules of engagement you agree in writing, because depth and findings depend on both that scope and the skill of the tester. The main takeaway: for PCI DSS, PCI SSC states that tests are typically white-box or grey-box, while black-box can need more time and resources to meet deliverables.

FactorBlack-boxGrey-boxWhite-box
Information the tester starts withNo information provided; starts from an outsider's viewPartial details, such as selected components or a user accountFull details of the network and applications
Typical goalShow what an outside attacker could reach and exploitShow what a user or insider with some access could reachFind as many exploitable weaknesses as possible in the agreed scope
ScopeSet in the rules of engagement; discovery uses part of the effortSet in the rules of engagement, with supplied details defining the start pointSet in the rules of engagement, with design and configuration details supplied
MethodReconnaissance and discovery first, then manual exploitationTargeted discovery, then manual testing from the supplied detailsManual testing against documented design, with code or configuration review where agreed
Depth of coverageNarrower; limited to what discovery exposesUsually broader than black-box, depending on the details suppliedBroadest for the agreed scope, depending on time and tester skill
Evidence producedFindings with CVE and CWE references, scope and limitations statedFindings with CVE and CWE references, plus the access level usedFindings with CVE and CWE references, plus the design basis tested
What it tends to missInternal flaws and logic issues behind controls it never reachesWeaknesses only reachable with access the supplied details left outGaps in the documents supplied and assumptions nobody has written down
Fit for PCI DSSPossible, but PCI SSC notes it may need more time, money and resourcesTypical choice per PCI SSC guidance; confirm acceptance with your assessorTypical choice per PCI SSC guidance; confirm acceptance with your assessor
Main cost driverDiscovery time and the extra effort to meet PCI DSS deliverablesNumber of roles and components in scope, and detail the client preparesVolume of design and configuration material to review, and any code review

Which access level to buy: the decision path from goal to scope

The path starts with your buying goal and asks first whether a framework such as PCI DSS, CIS Controls or a high-baseline NIST control requires a penetration test, since that requirement sets the minimum scope. If the question is what an outside attacker can reach, the path leads to black-box testing or grey-box testing with stated access. If the question is depth on configuration, design or code, it leads to white-box testing or grey-box testing with documents and code access. If the goal is a repeatable baseline, it leads to scheduled scanning with periodic penetration tests. Adversary simulation goals leave this page for the red teaming topic. Confirm each branch against the framework's wording and your written rules of engagement before you fix the scope.

Decision path from compliance requirement and goal to access level and scope.

How each test runs day to day, from the tester's side

Every penetration test moves through the four phases described in NIST SP 800-115: planning, discovery, attack and reporting. Planning sets the rules. Before any testing occurs, the rules are identified, management approval is finalized and documented, and testing goals are set. Appendix B of the guide provides a rules of engagement template, and it is a practical document to bring to vendor scoping calls because it gives both sides the same checklist. Ask each vendor to state the rules, approvals and goals in writing before discovery starts. A proposal that leaves them out is one you cannot check later.

The starting information changes what discovery costs and what it finds. In PCI SSC's terms, black-box testing gives the tester no information, white-box testing gives full details of the network and applications, and grey-box testing gives partial details. A black-box tester spends more early effort finding and identifying exposed targets before exploitation begins, and PCI SSC notes that a black-box assessment may need more time, money and resources to produce deliverables that meet PCI DSS requirements. A grey-box tester typically starts from partial details such as test accounts or architecture notes, so early discovery leans on what those details reveal. A white-box tester may review configuration, design or code alongside exploitation, so reading artifacts and attacking the system happen within the same engagement window.

Whatever the starting point, PCI SSC describes penetration testing as essentially a manual process and states that simply running an automated tool does not satisfy the penetration testing requirement. Ask which steps are manual. Request the list of tools each vendor plans to run, and ask how a tester validates tool output before it reaches the report. For a grey-box engagement, also confirm who supplies the test accounts and architecture notes, and when. Those handoffs decide how much discovery the tester must repeat, which affects the effort in the quote. Confirm that each finding comes with evidence of how it was validated.

What each approach finds and what it misses

The four approaches differ in what the tester knows and how much risk the work carries. NIST SP 800-115 calls review techniques passive and low risk, while penetration testing uses exploits against production systems and data, so access, change windows and approvals belong in the rules of engagement.

Black-box testing

Black-box testing gives the tester no information about the target, so it shows what an outsider can reach from the internet or without logging in. It tends to find what an outsider can reach, including exposed services, perimeter misconfigurations and flaws that need no account. It tends to miss functions behind authentication, internal code paths and most authorization logic. PCI SSC notes that a black-box assessment may need more time, money and resources to meet PCI DSS deliverables. Ask the provider which identities, if any, the tester starts with.

PCI SSC guidance

Grey-box testing

Grey-box testing gives the tester partial details, such as a standard user account, an API specification or an architecture overview. It tends to find broken access control between roles, workflow abuse and data a valid user can expose. It tends to miss flaws that only appear under a different role, and it sees only what the supplied credentials can reach. Use it when a valid user role or workflow is the concern, and confirm which roles, documents and environments are in scope before work starts.

White-box testing

White-box testing gives the tester full details of the network, the applications and, where agreed, the source code. It tends to find insecure configuration, weak defaults and code-level defects that outside testing cannot see. It tends to miss behavior in the deployed system that the supplied documents do not describe, so its results depend on whether that material matches production. Use it when configuration or code depth is the concern, and ask whether the provider will also test the running system.

OWASP WSTG v4.2

Vulnerability scanning and reviews

Scans and reviews identify, rank and report known weaknesses, mostly with automated tools, and NIST suggests running them on a regular schedule. They tend to find missing patches, known vulnerable versions and common misconfigurations across many hosts. They tend to miss business logic flaws, chained attacks and whether a finding is exploitable, and PCI SSC states that simply running an automated tool does not satisfy the penetration testing requirement. Use them when frequency across many hosts is the concern, and pair them with periodic penetration tests.

NIST SP 800-115

What you receive from each test and what to require in writing

This table lists the sections a penetration test report should contain, following the outline PCI SSC suggests in its penetration testing guidance, and what to write into the statement of work for each. Read the access column to see how black-box, grey-box and white-box access changes what the tester can reach and what the report can prove. The main takeaway is to agree the limitations and retest sections in writing before testing starts, because they decide what the report does and does not cover.

DeliverableWhat to require in the statement of workHow the access level changes it
Executive summaryPlain-language overall result, key risks and business impact, written for non-technical leaders.Black-box summaries often rest on fewer confirmed facts, so ask the tester to state what was confirmed.
Statement of scopeNamed systems, IP ranges, applications, accounts and environments in scope, with dates and excluded assets.Grey-box and white-box scopes name test accounts and design documents. Black-box scopes rely on the target list alone.
Statement of limitationsWhat the tester could not reach, such as blocked hosts, excluded systems, time limits and unavailable credentials.Black-box testers often cannot see internal paths, so this section must name the areas that stayed unseen.
Statement of methodology and tools usedStandard or method followed, phases, manual and automated steps, and tool names with versions.Access level changes which tools apply. Ask for manual and automated steps listed separately, since PCI SSC describes penetration testing as mainly manual.
Testing narrativeChronological account of each attack path, what was tried, what worked and what failed.White-box narratives can show code-level paths. Black-box narratives show what an outside attacker could reach.
Findings with CVE and CWE referencesEach finding with reproduction steps, affected asset, CVE where one exists and the CWE weakness class.Black-box findings may show a symptom only, so ask the tester to name the underlying CWE.
Severity basisScoring method, usually CVSS, with written reasoning for any score adjusted to fit your environment.Access level affects exploitability ratings. Each environmental adjustment must trace back to a stated assumption.
Retest resultsRetest after remediation to confirm each fix mitigates the original risk, with dated evidence per finding.PCI DSS 11.4.4 requires exploitable findings corrected by risk ranking and retested. Late fixes may need a new engagement.
Environment clean-upRemoval of test accounts, payloads, backdoors and data copies, with written confirmation of what was removed.Authenticated work usually creates more accounts and artifacts, so the clean-up list is longer than for black-box work.

How to combine the approaches in one testing program

Organizations often combine techniques to reach an in-depth assessment at an acceptable level of risk, as NIST SP 800-115 notes. This sequence sets the goal first, assigns an access level to each test, and ends with evidence that fixes and detections hold up.

  1. Set the goal and governing framework

    Start by writing down the question the program must answer, such as whether a payment environment is segmented or whether an outsider can reach a customer portal. Identify any framework that sets minimum testing, such as PCI DSS for cardholder data environments or CIS Controls v8.1 Control 18 for the wider program, and name the owner who signs off the goal. Done when the goal, framework and owner are recorded in one scope document that the security and compliance leads have both reviewed.

  2. Fix the access level for each test

    For each test, choose black-box, grey-box or white-box access based on what the goal needs, and record that choice in the rules of engagement. NIST SP 800-115 provides a rules of engagement template in Appendix B. Management approval must be finalized and documented before any testing starts, because the planning phase involves no testing at all. Done when the signed document lists the access level, the accounts or credentials issued to testers, the systems in scope and any out-of-scope items.

  3. Schedule scanning between penetration tests

    Set a recurring schedule for network and vulnerability scanning, which NIST SP 800-115 suggests running regularly and interspersing with periodic penetration tests. Scanners identify, rank and report vulnerabilities mostly through automated tools, so the internal team or a service provider triages the output and tracks fixes between tests. Scans do not replace a penetration test, since PCI SSC guidance says simply running an automated tool does not satisfy the penetration testing requirement. Done when the schedule, the owners and a triage log exist, and each scan result has a recorded disposition.

  4. Run the penetration test at required access

    Testers work at the access level fixed in the rules of engagement, moving through planning, discovery, attack and reporting as NIST SP 800-115 describes. Penetration testing is mainly manual work that exploits vulnerabilities to get past security features, so it takes longer than a scan. PCI SSC notes that a black-box assessment may need more time, money and resources to meet PCI DSS deliverables, which is worth raising when you compare quotes. Done when the report includes scope, methodology, limitations, a testing narrative and findings with the reasoning behind each severity rating, and the team has agreed which findings must be fixed first.

  5. Add external testing for outsider reach

    When the question is what an outsider can reach, run an external black-box or grey-box test against the internet-facing services, under rules of engagement written for that exposure. Black-box work starts with no information provided, while grey-box work starts with partial details, so the starting assumption shapes what the result means. Skip this step when the goal is purely internal, but keep in mind that CIS Safeguard 18.2 asks for external penetration tests at least annually. Done when the report lists which assets were reachable from outside, the access the tester started with, and the findings that exposed them.

  6. Retest and validate detections after fixes

    After remediation, retest the exploited findings to confirm that the new controls reduce the original risk, which PCI DSS requirement 11.4.4 also requires for exploitable vulnerabilities. Then compare the techniques the testers used with what security monitoring detected, as CIS Safeguard 18.4 asks, and log each gap with an owner. Retesting long after the original test may need a new engagement, so set that boundary in the scope document. Done when the retest report confirms closed findings and a detection coverage map shows which tested techniques were caught, missed or still open.

When compliance frameworks call for each approach

Start with the framework that sets the cadence. PCI DSS requires internal and external penetration tests at least every 12 months and after significant changes (requirements 11.4.2 and 11.4.3), so a test bought for a cardholder environment recurs every year at minimum. The PCI SSC Penetration Testing Guidance states that PCI DSS tests are typically white-box or grey-box, because partial or full design details give more accurate and comprehensive results. Check your next quote for the access level the tester will use. The same guidance notes that a black-box assessment may need more time, money and resources to produce deliverables that meet the requirements, so ask the tester to justify any black-box element in writing.

CIS Controls v8.1 Safeguards 18.2 and 18.5 ask for external and internal penetration tests at least annually. Safeguard 18.2 fails the CIS assessment metric if more than twelve months pass since the last external test, so the calendar carries as much weight as the access level for that control. NIST SP 800-53 control CA-8 (Penetration Testing) applies in the high baseline of SP 800-53B Release 5.2.0, and its enhancements cover an independent penetration testing team and red team exercises. If your system falls in the high baseline, write the independence requirement into the statement of work. Ask the tester how it demonstrates independence from the team that builds or operates the system, and confirm whether a red team exercise is in scope or a separate purchase.

For EU financial entities, DORA Article 25(1) lists tests including vulnerability assessments, source code reviews where feasible and penetration testing. Article 26 requires threat-led penetration testing at least every 3 years, but only for entities that their competent authority identifies. Confirm your status with your regulator before budgeting for threat-led work, and ask whether the authority specifies the access level it expects. Across all of these frameworks, the assessor or regulator decides which access level is accepted, so get that decision in writing before the test starts. DeployOpen prepares scope records, test evidence and control documentation for a compliance assessment, but it does not issue audit reports or certifications. Independent auditors and certification bodies do that work.

What drives the cost of black-box vs grey-box vs white-box testing

Six cost components separate a black-box quote from a white-box quote, and most of them are settled before any testing starts. Scope, access, environment, evidence, retests and tester experience each decide who does which work and who pays for it. Compare quotes line by line on these six items so the price differences reflect the same work.

Scope: hosts, applications and APIs

Scope is the largest single cost driver, because tester time grows with every host, application, API and environment in the statement of work. Count each target before you compare quotes. Ask whether the price is per environment, per application or per day, and whether a single application with many API endpoints is priced as one target. Scope is set once, but a change after signature usually needs a written change order. Your team pays for an accurate inventory; the vendor pays testers to work through each target.

Access and preparation effort

PCI SSC notes that a black-box assessment may need more time, money and resources to meet PCI DSS deliverables, because testers must first find the targets. Grey-box and white-box work moves that discovery to your team: test accounts, architecture documents and code access must be ready before testing starts. Preparation is an internal cost that recurs. Accounts expire, architecture drifts and code access changes between cycles. Ask which access the vendor needs, who provisions it, and whether discovery time is already in the quote.

PCI SSC guidance

Production or staging environment

Testing in production carries more risk and more coordination than testing in staging. NIST SP 800-115 says penetration testing uses real exploits against production systems and data and carries high risk, so approvals, rules of engagement and change windows add effort on both sides. Your team pays for approvals, freeze windows and on-call cover, while the vendor pays testers to work inside those limits. Staging only gives useful results if it mirrors production. Ask whether the quote covers after-hours work, who signs the rules of engagement, and who halts testing if a system degrades.

Depth of evidence and report

PCI SSC's suggested penetration test report includes scope, methodology, limitations, a testing narrative, findings referenced to CVE and CWE, and the tools used. Deeper evidence, such as proof of exploitation, attack paths and segmentation results, takes more tester hours and a longer write-up. Ask for a sample report before you sign. Check that severity ratings explain how they were derived, typically from CVSS, and that any environmental adjustment is traceable. The report is a one-time deliverable, but its depth decides how much your remediation team can act on without a second round of questions.

Retests and remediation cycles

PCI SSC says the tester should retest once remediation is complete, and that a fix finishing long after the original test may need a new engagement. PCI DSS requirement 11.4.4 requires exploitable findings to be corrected by risk ranking and the test repeated to verify the fixes. Retests recur with every remediation cycle. Confirm whether one retest is in the fixed price, how many rounds are included, and whether a retest after the agreed window becomes a new test. PCI DSS also requires internal and external tests at least every 12 months and after significant changes, which adds a recurring cost on top of retests.

Tester experience and credentials

PCI SSC lists OSCP, GIAC certifications such as GPEN and GWAPT, CREST penetration testing certifications and CHECK as indicators of tester skill, but says certifications alone do not establish experience. CREST accredits companies and certifies individuals, so you can ask for both. Ask who will test and what they have done on targets like yours. Cost sits mainly in tester hours, and a senior reviewer adds hours on top of them. Confirm that the named testers, not a changing pool, return for the retest, and ask how staff turnover between annual tests is handled.

CREST about us

Questions buyers ask before choosing a test approach

Is black-box penetration testing cheaper than grey-box testing?

Not necessarily. Black-box testing gives the tester no prior information, and PCI SSC's penetration testing guidance says a black-box assessment may need more time, money and resources to produce the deliverables a PCI DSS assessment expects. Cost follows effort, and effort follows how much the tester must discover before attacking. Grey-box testing starts with partial details such as accounts, architecture notes and scope lists, which shortens discovery but adds preparation work for your team. White-box testing adds design and source access, which raises the cost of reviewing that material. Ask each bidder to quote the same target at each access level so you can compare the trade-off in writing. Confirm which deliverables the scope must produce, because a lower quote that omits a required report or retest does not reduce total cost.

How long does a penetration test take to complete?

Duration depends mainly on scope, not on the access level alone. PCI SSC describes penetration testing as a mainly manual process that exploits vulnerabilities to get past security features, and says a test may last days or weeks depending on scope. The main drivers are the number of applications, networks and segments in scope, how many environments are tested, how complex authentication is, and how many user roles must be tested for access control. Your team's speed in answering questions and providing test accounts also affects the calendar. Ask the provider to state the timeline in the written scope, including start and end dates, the testing window, any blackout periods, and whether validation of findings or retesting is included. Illustrative example: one web application with two user roles usually takes less time than the same application plus its API and mobile client.

What do we need to provide for grey-box testing?

Grey-box testing needs your team to supply partial information before testing starts: test accounts, architecture notes, a scope list and named contacts. Test accounts should cover each user role the test must exercise, with the permissions those roles hold in production or in a close copy. Architecture notes should show the main components, data flows, trust boundaries and third-party services, so testers do not spend billable time rediscovering them. The scope list should name hosts, domains, applications and address ranges, and state what is out of bounds. Named contacts should include someone who approves testing windows, someone who can stop the test if production is affected, and someone who answers questions during the test. This preparation is effort on your side, and it recurs with each test unless the documents stay current. Ask the provider which items they need before quoting, and confirm who on your side owns each one.

Can our own engineers run a penetration test in-house?

Your own team can run a penetration test only if the people doing the work have the skills and independence your assessor will accept. PCI SSC describes penetration testing as mainly manual work and says that simply running an automated tool does not satisfy the requirement, so a team that only launches scanners will not produce a valid test. Check tester qualifications against the credentials PCI SSC lists as indications of skill, and ask whether the assessor requires testers who are independent of the teams that built or operate the system. In-house testing reduces direct spend on external work, but it adds staff time, tooling, training, and the risk that people testing their own systems miss what they assume is secure. Ask your assessor before you start whether internal results will be accepted for the compliance requirement, and what evidence and report format they expect.

Is a vulnerability scan enough instead of a penetration test?

No. A vulnerability scan identifies, ranks and reports known weaknesses using mostly automated tools, and PCI SSC notes that scans take seconds to minutes per host. A penetration test is a mainly manual process that attempts to exploit vulnerabilities, so it shows whether a weakness can be used to reach something that matters in your environment. Scans and penetration tests answer different questions and are usually scheduled separately. Scans cost less per host because the effort per target is lower, while penetration tests cost more per target because a tester spends time on each attack path and explains how the steps connect. The cost driver for scans is host count and frequency. For penetration tests it is scope depth, access level and the number of attack paths tested. Confirm with your assessor which scan cadence and which penetration test cadence your standard requires.

Do security certifications prove a penetration tester is good?

No. A certification shows that an individual passed an exam or that a company is accredited, but it does not prove that a specific engagement will be thorough. PCI SSC states that it does not validate or endorse the certifications its guidance lists, and that certifications alone do not establish experience. Those examples include OSCP, GIAC certifications such as GPEN and GWAPT, CREST penetration testing certifications and CHECK. CREST is a UK not-for-profit that accredits member companies and certifies individuals, and you can read more in CREST: About us. Use certifications as one screening input, then ask for a sample methodology, a sample report, the named testers' experience with your technology, and references you can verify. Ask who will perform the work, because the people in the sales meeting are not always the testers.

How often do we need to repeat penetration testing?

Penetration testing recurs, so the cadence drives long-term cost. PCI DSS requires internal and external penetration tests at least every 12 months and after significant changes, so budget for testing as a recurring line item rather than a one-off project. A significant change, such as a major application release, a new network segment or a changed payment flow, can trigger a new test before the annual date. PCI SSC's guidance also expects testers to retest once remediation is complete to confirm that the new controls address the original risk, and notes that remediation completed long after the original test may require a new engagement. Ask each provider whether retesting is included in the quote, how many retests are covered, and the period they allow. Confirm with your assessor what counts as a significant change in your environment.

How DeployOpen scopes, runs and retests black-box, grey-box and white-box tests

DeployOpen runs security testing and documents every engagement, so the access level for black-box, grey-box or white-box work is set in writing before any testing starts, which keeps each result tied to a known level of access. Most engagements are fixed-scope, so scope, deliverables and timelines are agreed in writing before work begins.

How we scope

  • Black-box scope should state in writing what the tester may discover, and what is out of bounds.
  • Grey-box and white-box scopes list the test accounts, roles, documentation or source code the tester receives.
  • Rules of engagement, testing windows and escalation contacts are agreed in writing before work starts.

How we run the tests

  • Testing combines automated scanning with manual exploitation, because scanner output alone does not show exploitability.
  • Each access level follows the same written method, so findings from each level can be compared.
  • Findings are logged with reproduction steps, affected components and a severity rationale that reviewers can trace.

How we hand over

  • Deliverables are listed in the written scope, so the report format is agreed before testing starts.
  • Reports state the testing method and limitations, so auditors and reviewers can judge how much each result supports.
  • Compliance evidence is prepared for your assessor, though DeployOpen does not issue audit reports or certifications.

How we support

  • A retest after remediation can be included in the written scope to confirm fixes hold.
  • Ongoing support, upgrades and continuous testing are available as retainers after the initial engagement ends.
  • Ask for a quote built from the written scope, because DeployOpen does not publish a price list.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.