agentleFS
K95M65K95M65/AI_ONBOARD/skills/map-attack-surface/SKILL.md

map-attack-surface

Skill0 starsChanged 4 months agoMITView on GitHub

Maps an owned or explicitly authorized system's internal, external, or combined attack surface into an evidence-backed asset ledger, reachability model, and prioritized attack paths. Use when inventorying exposed assets, reconciling shadow IT, scoping a security assessment, understanding trust and privilege boundaries beyond one codebase, or establishing a baseline for continuous exposure management. Passive discovery is the default; active probing requires explicit targets and rules of engagement.

The file

Show its rules and text

We split this skill into the rules it gives an agent

20 rules. About 0 are common, 13 are distinctive, and 7 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈13

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Keep discovery separate from vulnerability testing: this skill establishes coverage and attack paths, then routes deeper assessment to …

    line 9
  2. Distinctive:

    Read references/authorization-and-scope.md.

    line 21
  3. Very specific:

    If ownership or authorization is ambiguous, do not produce an attack-surface ledger, attack paths, or security-target priorities.

    line 23
  4. Very specific:

    Use conduct-open-source-investigation for a substantial public-source evidence investigation.

    line 29
  5. Very specific:

    Use threat-model after the surface exists to apply STRIDE to important flows and boundaries.

    line 30
  6. Very specific:

    Use security-audit to inspect an application or codebase for concrete vulnerabilities.

    line 31
  7. Very specific:

    Use manage-vulnerability-risk when findings need prioritization, ownership, remediation, and retesting.

    line 32
  8. Very specific:

    Use assess-security-controls when the question is whether defined controls are designed and operating.

    line 33
  9. Very specific:

    Use vulnerability-hardening, identity-management, secret-scan, or dependency-vuln-scan for their bounded remediation or testing jobs.

    line 34
  10. Distinctive:

    Do not repeat those procedures inside the surface map.

    line 37
  11. Distinctive:

    Start with authoritative inventories and configuration, then compare them with observed sources.

    line 52
  12. Distinctive:

    Do not make a paid service, API key, account signup, or new scanner installation a prerequisite.

    line 56
  13. Distinctive:

    Use assets/attack-surface-ledger-template.md when a durable artifact helps.

    line 61
  14. Distinctive:

    Keep ambiguous assets separate until evidence supports a merge.

    line 73
  15. Distinctive:

    Read references/analysis-and-monitoring.md.

    line 90
  16. Distinctive:

    Call out unknown owners, conflicting inventories, unmanaged identities, stale assets, unmonitored zones, unsupported systems, third-party …

    line 94
  17. Distinctive:

    Use an independent reviewer to challenge ownership, source independence, missing asset classes, and attack path assumptions when available.

    line 99
  18. Distinctive:

    Never exploit, bypass access controls, spray credentials, persist, exfiltrate, socially engineer, or run destructive or high-volume tests …

    line 115
  19. Distinctive:

    Never expand from an authorized asset to a related third party without separate authority.

    line 117
  20. Distinctive:

    Stop active work when a target behaves unexpectedly, scope cannot be confirmed, or safety thresholds in the rules of engagement are reached.

    line 119

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Map attack surface

Produce a defensible map of what can be reached, what it connects to, what it protects, and who owns it. Keep discovery separate from vulnerability testing: this skill establishes coverage and attack paths, then routes deeper assessment to narrower skills.

Establish authority and scope

  1. Name the organization, system, environments, business objective, time window, and decision owner.
  2. Record target inclusions and exclusions using exact identifiers where possible: repositories, accounts, tenants, domains, CIDRs, applications, facilities, or business units.
  3. Classify the permitted action level before collecting:
    • Passive: inspect supplied artifacts and public records without sending probes to a target.
    • Authorized read-only: query an approved inventory, cloud, directory, logging, or security system.
    • Authorized active: send bounded discovery or validation traffic under written rules of engagement.
  4. Read references/authorization-and-scope.md. Do not infer that a hostname, shared-cloud address, vendor portal, or public record is owned or authorized.
  5. If ownership or authorization is ambiguous, do not produce an attack-surface ledger, attack paths, or security-target priorities. Ask for authority or route proportionate general public-source research to conduct-open-source-investigation; do not widen it into security reconnaissance.

Route adjacent work

  • Use conduct-open-source-investigation for a substantial public-source evidence investigation.
  • Use threat-model after the surface exists to apply STRIDE to important flows and boundaries.
  • Use security-audit to inspect an application or codebase for concrete vulnerabilities.
  • Use manage-vulnerability-risk when findings need prioritization, ownership, remediation, and retesting.
  • Use assess-security-controls when the question is whether defined controls are designed and operating.
  • Use vulnerability-hardening, identity-management, secret-scan, or dependency-vuln-scan for their bounded remediation or testing jobs.

Do not repeat those procedures inside the surface map.

Build the map

1. Select the view

  • For enterprise, cloud, SaaS, identity, endpoint, network, CI/CD, and administrative surfaces, read references/internal-mapping.md.
  • For internet-reachable and publicly discoverable assets, read references/external-mapping.md.
  • For a combined assessment, read both and preserve an internal, external, or both marker on each record.

2. Collect from independent sources

Start with authoritative inventories and configuration, then compare them with observed sources. Record the source, retrieval time, collection method, and scope for every import or observation. Treat absence from one source as a coverage question, not proof that an asset does not exist.

Do not make a paid service, API key, account signup, or new scanner installation a prerequisite. Use free, local, public, or already-authorized capabilities available in the environment.

3. Normalize and establish ownership

Use assets/attack-surface-ledger-template.md when a durable artifact helps. Deduplicate aliases without erasing source provenance. Assign:

  • a stable asset identifier and asset class;
  • business and technical owners, or an explicit unknown;
  • environment and lifecycle state;
  • source-backed ownership confidence;
  • internal and external reachability;
  • identities, privileges, trust zone, and administrative plane;
  • data sensitivity, business criticality, and dependencies; and
  • last observed date and monitoring source.

Keep ambiguous assets separate until evidence supports a merge.

4. Model exposure and attack paths

Draw a compact graph or table from potential actor to entry point, identity or control boundary, dependent asset, protected data or capability, and plausible outcome. Include unauthenticated access, ordinary users, privileged users, machine identities, vendors, and insiders where relevant.

Distinguish:

  • observed reachability from inferred reachability;
  • an exposure from a vulnerability;
  • a control presence from verified control effectiveness; and
  • a plausible path from a demonstrated path.

5. Prioritize and identify coverage gaps

Read references/analysis-and-monitoring.md. Rank paths using exposure, privilege, asset criticality, data sensitivity, control strength, and confidence. Do not assign false numerical precision when evidence is incomplete.

Call out unknown owners, conflicting inventories, unmanaged identities, stale assets, unmonitored zones, unsupported systems, third-party dependencies, and areas the collection method could not observe.

6. Review and report

Use an independent reviewer to challenge ownership, source independence, missing asset classes, and attack path assumptions when available. Use a verifier to reproduce a sample of high-impact records and confirm that the report does not imply active validation that did not occur.

Report:

  • scope, authority, action level, assumptions, and exclusions;
  • source and coverage summary;
  • asset ledger and ownership gaps;
  • high-priority exposure and attack paths with confidence;
  • unknowns and conflicting evidence;
  • routed next assessments and remediation owners; and
  • a monitoring plan for detecting material surface change.

Safety rules

  • Never exploit, bypass access controls, spray credentials, persist, exfiltrate, socially engineer, or run destructive or high-volume tests as part of mapping.
  • Never expand from an authorized asset to a related third party without separate authority.
  • Minimize personal data and secrets in the ledger; link to protected evidence rather than copying it.
  • Stop active work when a target behaves unexpectedly, scope cannot be confirmed, or safety thresholds in the rules of engagement are reached.

Completion standard

The map is complete when a decision-maker can see what was covered, which assets are owned, how important assets may be reached, where evidence is weak, what requires deeper assessment, and how material change will be detected.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.