What's the difference between an attack-surface scan and a vulnerability scan? Seeds versus target lists, breadth versus depth, what each one cannot see, scope, and how to run them together

DedSec Security Research · · Updated

An attack-surface scan starts from something you own, usually a domain name, and finds what you expose to the internet: the names, hosts, services and certificates that answer, and which of them are actually yours. A vulnerability scan starts from a list of targets you supply and tests each one in depth for known weaknesses. The first answers "what do we have out there?"; the second answers "what is wrong with this thing we already know about?". Each is blind where the other looks: a clean vulnerability scan says nothing about an asset that was never on its list, and an attack-surface inventory says little about what sits behind a login page.

That is the short answer. The rest of this post is the mechanism: what each scan takes as input, what it actually sends to a host, where the two overlap and why the overlap produces the weakest findings either one makes, why feeding one straight into the other can put someone else's server in your test scope, and how to run them together, with code scanning as a third, different view. Everything here is general practice unless a section says otherwise. Names use example.com and the .example top-level domain reserved by RFC 2606, and addresses come from the documentation ranges in RFC 5737. The organisation in the example is invented.

A worked case

An organisation's security team runs a vulnerability scanner every month against a target list: a few dozen addresses and a handful of web application URLs, exported from the cloud console and the asset register when the scanner was set up. The reports are clean, or close to it. Meanwhile:

None of this is a scanner bug. The scanner tested exactly what it was given, and two of the three problems are about what it was given. An attack-surface scan starting from example.com has a good chance of finding the staging host, because a certificate issued for that name is in the certificate transparency logs and the name is in the company's DNS. Compared against the scanner's target list, its inventory would also show that no name the company controls resolves to the released address any more. It may well miss the agency domain, because nothing in example.com's DNS, certificates or registration data points at it. And it would say much less than the vulnerability scanner about whether the payments build is exploitable.

The input decides what can be found

The most important difference is the input, because everything downstream inherits it.

An attack-surface scan takes a seed. Usually a registered domain; sometimes a legal entity name, an autonomous system number or a few known addresses. From the seed it expands outward through sources any outsider can reach:

The output is a candidate inventory: names, addresses, services and certificates, and the observed relationships between them (this name resolved to this address, this service presented this certificate). A candidate is not yet an asset. That takes attribution, which comes up again under scope.

A vulnerability scan takes a target list. Addresses, ranges, hostnames or application URLs that someone typed, imported or synchronised, plus a policy that says which ports and checks to run and, optionally, credentials. Network scanners do perform host discovery, but inside the ranges they are given: they find which addresses in 203.0.113.0/24 respond, not that you also run something in a different provider's range. A DAST scanner crawls from a starting URL and discovers routes within that application, not other applications.

So the two scans ask different questions:

The second question has an assumption built in. If the list is incomplete, it is silently incomplete: the report covers every target it was given and has no way to mention the ones it was not. That is the same shape as the problem in the scan passed is not the scan ran: an absence of findings means something only relative to what was actually examined.

Breadth versus depth: what each scan sends to a host

Ask what each tool actually sends, and the difference becomes concrete.

An attack-surface scan touches many objects lightly. For each candidate it typically resolves the name, connects to common ports, completes a TLS handshake and reads the certificate, fetches a page or two, records the headers, and identifies the service and technology from what came back. Many of its exposure checks read only what any visitor receives: certificate validity and chain, protocol versions offered, security headers, DNS records pointing at deprovisioned targets, email authentication records, an administration login page answering on the internet. The posts on security headers, DNS hygiene findings, TLS drift and dangling DNS cover what that class of check can and cannot conclude.

A vulnerability scan touches few objects heavily. Against one host, a network scanner may probe the whole TCP port range and selected UDP ports, run service detection on each listener, then run whichever of its checks match what it found, some of which send traffic shaped like the attack. Against one web application, a DAST scanner crawls routes, then sends payloads into each parameter it found, in each place the parameter lives (path, query string, body, header, cookie), and compares the responses for signs of injection, reflection, timing differences or out-of-band callbacks.

The trade-off is cost and risk per object. Running a full DAST policy against every hostname an attack-surface scan finds would take a long time, would send attack-shaped traffic to hosts nobody has checked you own, and would spend most of its effort on brochure pages and other companies' login screens. Running only light checks against a payments API misses everything that needs a parameter fuzzed. Breadth and depth are not two ends of one setting; they are different jobs.

The depth side has a coverage problem of its own: a deep scan of a listed application still tests only the routes it reached. The DAST coverage post covers how crawl limits, lost sessions and unlinked APIs leave parts of an in-scope application untested while the report reads clean.

Authenticated and unauthenticated

An attack-surface scan is unauthenticated by design. It measures what someone with no credentials can reach, which is exactly where an attacker starts. That makes it good evidence about exposure ("this admin panel answers on the internet") and weak evidence about anything past the first login form.

A vulnerability scan can go either way, and the difference changes what its findings mean:

The views are complementary. A credentialed scan finding an unpatched library says it is present. An unauthenticated outside view says whether anyone on the internet can reach the service that uses it. A finding with both behind it is a different priority from a finding with one.

What each one cannot see

A vulnerability scanner cannot see:

An attack-surface scan cannot see:

Where they overlap, and why the overlap is weak

Both kinds of scan fingerprint services, and both commonly turn a fingerprint into a CVE. An attack-surface tool reads an SSH identification string or an HTTP Server header and reports that the version is inside an advisory's affected range. An unauthenticated network scanner reading the same bytes reports the same thing. It is the finding the two most often produce in common, and it is the weakest evidence either one offers.

The chain from banner to CVE loses information at every step. The banner is whatever the service chose to send: it can be stripped, edited, or sent by a load balancer or proxy rather than the origin. Distributions backport security fixes without changing the upstream version number, so a fully patched package can carry an "affected" version string. And the step from fingerprint to CPE to advisory range usually drops the distribution package revision, which is often the detail that decides the case. The version banner post works through CVE-2024-6387 against real distribution records and grades this kind of finding on four levels: banner-inferred, config-inferred, behaviourally confirmed, and validated with evidence.

Two practical rules follow for anyone running both scans:

  1. Agreement is not corroboration. When the attack-surface tool and the vulnerability scanner flag the same banner, that is one observation reported twice. Both read the same bytes from the same listener.
  2. Resolve the overlap on the side that can. A credentialed scan, or one package-manager query on the host, settles a backport question. The outside view is good at telling you which hosts have the question; it is the wrong instrument for answering it.

The overlap also creates duplicates. If both tools report the same issue on the same host and nothing matches them, the issue becomes two findings with two owners and two closure states, and fixing it closes one and leaves the other open until somebody notices. The finding identity post covers how keys for hosts and services break when addresses rotate and certificates renew, which is exactly where findings from two tools have to be joined.

Scope: you may only test what you are authorised to test

Here the two scans differ in a way with consequences beyond accuracy.

An attack-surface inventory will contain hosts you do not operate, because enumeration finds things that respond, not things you own. A CDN edge serving your hostname serves other customers from the same address. A SaaS help centre on your CNAME runs on the vendor's infrastructure. Address ranges reached through an SPF include belong to your email provider. A look-alike domain with your company name typed into its registration record belongs to whoever registered it. Each of these is relevant as exposure, and none of them is yours to attack.

Reading what any visitor receives (resolving the name, completing a handshake, fetching a public page) is what any browser does. A light connection to common ports goes a step past that, and many teams put it under scope as well. Active testing is a different act: injection payloads, exploit validation, credential attempts, aggressive port scanning. Running it against a host needs authorisation from whoever operates that host. A cloud provider's published testing policy, where it has one, covers resources in your own account, not other tenants on the same platform.

So the dangerous configuration is the obvious automation: take everything the attack-surface scan found and hand it to the vulnerability scanner as targets. Every attribution error becomes an unauthorised test. The released address in the worked case is the quiet version of this, a stale entry in a static list. The loud version is a full DAST policy fired at a vendor's login page because it sits on a name under your domain.

The control, set out in more detail in the attribution post, is to keep two lists:

Discovery can propose additions to scope. It should not make them.

Cadence and change detection

The two scans have different natural rhythms, and the gap between them is where assets go untested.

A deep vulnerability scan is expensive per target, so it typically runs on a schedule or at release time, against a list that changes when somebody updates it. Between list updates, a new asset is not scanned however often the scanner runs. Running a fixed-list scanner every day does not make it notice a host created yesterday.

An attack-surface scan is cheaper per object and built to repeat. Its most useful output is often not the inventory but the difference between runs: what appeared, what changed (a CNAME now pointing at a different vendor, a new open port on an old host, a certificate for a name nobody recognises) and what disappeared. The change detection post covers the hard parts of that diff: what counts as one asset, how to keep CDN and certificate churn out of it, and how to tell "gone" from "did not answer". It also makes a point that matters here. The first run reports nothing as new, so everything already exposed on day one has to be reviewed as a baseline rather than waited for as a change.

Certificate transparency narrows the window between scheduled runs. Because major browsers reject publicly trusted certificates that lack proof of certificate transparency logging, a certificate for a new name under your domain is normally logged at or around issuance, which can be before the host serves any traffic, so watching the logs gives you an event to act on instead of waiting for the next enumeration. Wildcard certificates are the limit: a certificate for *.example.com tells you nothing about which names use it.

The combination that closes the gap is event-driven. A new attributed asset, or a material change to an existing one, triggers a scope decision and, if the asset is in scope, a vulnerability scan of it then, rather than at the next scheduled run.

Using them together

Run together, the two scans form a loop rather than two separate reports.

  1. Discover. The attack-surface scan expands from your seeds and produces a candidate inventory, plus change events between runs.
  2. Attribute. Each object is classified (ours, our name on a third-party host, candidate, rejected) with the evidence recorded.
  3. Decide scope. A person, or a rule a person wrote and reviews, decides which attributed assets get active testing and at what intensity. A brochure site might get only the passive checks; a customer-facing API gets an authenticated DAST policy.
  4. Test in depth. The vulnerability scanner runs against the scoped list, with credentials where they make the result more accurate.
  5. Join the findings. Findings from both tools are matched on a shared asset identity, so one issue has one owner and one state.
  6. Feed back. A scoped target that stops resolving, or that now resolves to an address outside anything you hold, is an attack-surface event, not just a failed scan. Take it out of scope until someone re-attributes it.

Each step has a characteristic failure. If discovery is noisy, scope review turns into a backlog and people start approving in bulk, which is how third-party hosts end up being tested. If the vulnerability scanner reports an unreachable target as clean rather than as not scanned, step 6 never fires. Ask both tools how they report what they could not do.

The third view: inside-out

Both scans above work from the outside. They observe a running system and infer what is wrong with it. Application security has a third view that works from the inside, and it is a different thing again, not a deeper version of either.

The three views correct each other's assumptions. SCA says a service ships a vulnerable library. The attack-surface scan says whether that service has a public hostname at all. DAST says whether the running endpoint behaves the way the advisory predicts. Each removes an assumption the previous one had to make, and a team running only one of the three is assuming the answers the other two would have given.

The comparison in one table

Attack-surface scan (EASM)Vulnerability scan (network or DAST)Code scan (SAST, SCA, secrets)
Starts fromA seed: domain, entity name, ASNA target list and a scan policyA repository
Question it answersWhat do we expose, and is it ours?What is wrong with this known asset?What are we about to ship?
Shape of coverageWide and shallowNarrow and deepEverything in the repository, nothing about deployment
CredentialsNone, by designOptional; credentialed scans see moreRead access to the code
Typical checksEnumeration, attribution, fingerprinting, TLS, headers, DNS and email recordsPort and service checks, CVE checks, injection payloads, authenticated crawlingTaint analysis, dependency matching, secret patterns
Cannot seeLogic behind a login, source code, assets with no link to a seedAnything not on the list, changes of ownershipWhether code is deployed or reachable from outside
Main risk when misusedThird-party hosts treated as yoursFalse confidence from a stale listFindings with no exposure context
Natural cadenceContinuous or scheduled, with diffsScheduled or per releasePer commit or pull request

Trade-offs worth naming

Where Maphra and AppSecD fit

Maphra is an external attack surface management platform, the attack-surface column of the table, though it starts from a domain name rather than any of the other seeds listed there. It needs a domain name to start, with no agent and no credential into your estate, and works outward: enumerating subdomains, resolving infrastructure, fingerprinting live services and attributing each discovered asset back to the organisation that owns it. Its product page answers the question in this post's title in one line: a scanner tests a list of assets you give it, while Maphra finds the assets first, including the ones nobody remembered, attributes them to your organisation, then analyses them. Every discovered asset is fingerprinted and checked for exposure, including service versions, certificate and TLS posture, security headers, DNS hygiene and takeover-prone records, and each finding carries the raw response that produced it. Maphra monitors certificate transparency, re-runs discovery on a schedule and diffs the result against the last known surface, reporting what appeared, what changed and what disappeared. Active checks validate exploitability against the live asset within an explicit scope boundary you define, and the scope gate prevents active checks from reaching third-party hosts that merely appear in your surface. Findings are deduplicated across scans and tracked through new, reopened and fixed states.

AppSecD covers the DAST part of the depth column and the inside-out column. Its DAST and API testing exercise the deployed application with 150+ native checks alongside Nuclei, Dalfox, SQLMap, Commix, Katana, Arjun and FFuf, Interactsh for out-of-band detection, and API discovery across 50+ web frameworks. It also runs SAST, SCA, secret detection across the full git history, IaC, container and Kubernetes scanning against one deduplicated finding model, and gates pull requests and commits by policy.

That is the whole claim. This post does not claim that Maphra and AppSecD exchange asset lists or findings, that either product implements the inventory-and-scope workflow, the attribution classes or the event-driven scanning described above, that Maphra runs credentialed scans, or that AppSecD runs authenticated DAST or credentialed host scans. The comparison, the loop and the trade-offs are general practice, and the questions below apply to any tool, ours included.

Questions to ask of either kind of tool

  1. Where did this asset come from: which seed, which source, and what evidence attributed it to us?
  2. Where does the target list come from, when was it last updated, and what happens when a target stops resolving?
  3. What does the report say about targets it could not reach or could not authenticate to: not scanned, or clean?
  4. What exactly does an active check send, and what stops it from reaching a host we do not operate?
  5. Is a version-based finding labelled as inferred from a banner, or as confirmed?
  6. When both tools report the same issue, is it one finding or two?

Frequently asked questions

Is an EASM tool a vulnerability scanner?

Not primarily. Its core job is discovery and attribution: finding what you expose and deciding which of it is yours. EASM tools commonly run exposure checks on what they find, such as TLS, headers, DNS and version fingerprinting, and those overlap with a vulnerability scanner's lightest checks. Credentialed host checks and authenticated testing of application logic are the vulnerability scanner's territory.

Do I need both?

If your asset list is complete and current, a vulnerability scanner alone can test it. An attack-surface scan exists to check that assumption from the outside, because a list built from memory, an asset register or one cloud account has no way to report what it is missing. If you run only an attack-surface scan, you know what is exposed but not whether the applications on it can be exploited past the front page.

Can a vulnerability scanner discover assets on its own?

Within the ranges or applications you give it, yes: network scanners find live hosts in a range, and DAST crawlers find routes in an application. Neither expands outward to names, providers or domains outside its input. Some vulnerability-management products bundle a separate discovery module; that module is doing an attack-surface scan, with the same attribution and scope questions. Discovering hosts inside a range is not discovering the range.

Can I run a vulnerability scan against everything an attack-surface scan found?

Not without checking first. The inventory contains hosts operated by CDNs, SaaS vendors, email providers and sometimes impersonators, and active testing of those needs their operator's authorisation. Decide scope from attributed assets, and re-check each target's current resolution when the test runs.

How often should each one run?

Run discovery often enough that the time between an asset appearing and you noticing it is a window you would accept, and watch certificate transparency for events between runs. Run deep scans when something changes, such as a new in-scope asset or a deployment, as well as on a schedule, because a fixed schedule against a fixed list never sees what was added in between.

A vulnerability scan is only as complete as its target list, and an attack-surface scan is only as useful as what is done with the list it produces. Run the second to keep the first honest.

More about Maphra · All posts