agentleFS
ViviBeriViviBeri/webcraft-pro/skills/secure-application-design/SKILL.md

secure-application-design

Skill11 starsChanged 10 days agoMITView on GitHub

Use when designing a web application threat model, reviewing architecture boundaries, choosing security controls, or translating OWASP requirements into engineering tasks.

The file

We split this skill into the rules it gives an agent

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

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈7

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Model threats: Use STRIDE or another documented method.

    line 17
  2. Distinctive:

    Trace abuse cases: Consider account takeover, cross-tenant access, mass assignment, injection, SSRF, unsafe file handling, business-flow …

    line 18
  3. Distinctive:

    Map requirements: Use OWASP ASVS 5.0.0 as a verification baseline and the API Security Top 10 for API-specific risks.

    line 20
  4. Distinctive:

    Revisit the model: Update it when architecture, data sensitivity, integrations, roles or deployment change.

    line 22
  5. Distinctive:

    Treat browser state, client-supplied identifiers and hidden UI controls as untrusted.

    line 28
  6. Distinctive:

    Use defense in depth without treating one control as a substitute for another.

    line 29
  7. Distinctive:

    Avoid storing sensitive data unless the product requires it.

    line 32

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 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

Secure Application Design

Objective

Build security into system boundaries and data flows before implementation. Use threat modeling to identify assets, trust boundaries, abuse cases and controls that can be verified.

Workflow

  1. Understand the system. Map browser clients, APIs, services, identity providers, databases, queues, object storage, external integrations and deployment boundaries.
  2. Identify assets. Classify credentials, personal data, payment or business records, session identifiers, source code, audit events and privileged operations.
  3. Map trust boundaries. Mark where identity, input, data ownership, network trust or execution privileges change.
  4. Model threats. Use STRIDE or another documented method. Include spoofing, tampering, repudiation, information disclosure, denial of service and privilege escalation.
  5. Trace abuse cases. Consider account takeover, cross-tenant access, mass assignment, injection, SSRF, unsafe file handling, business-flow abuse, resource exhaustion and compromised dependencies.
  6. Select controls. Define authentication, authorization, validation, output encoding, cryptographic protection, rate limits, logging, monitoring and recovery controls.
  7. Map requirements. Use OWASP ASVS 5.0.0 as a verification baseline and the API Security Top 10 for API-specific risks. Select requirements appropriate to the application's risk and deployment.
  8. Create actionable tasks. Assign each risk an owner, mitigation, verification method and residual-risk decision.
  9. Revisit the model. Update it when architecture, data sensitivity, integrations, roles or deployment change.

Design principles

  • Minimize exposed functionality, privileges, data and network reachability.
  • Enforce security decisions on trusted server-side components.
  • Treat browser state, client-supplied identifiers and hidden UI controls as untrusted.
  • Use defense in depth without treating one control as a substitute for another.
  • Fail closed for access-control and security-sensitive decisions.
  • Separate administrative and user-facing capabilities.
  • Avoid storing sensitive data unless the product requires it.

Deliverables

Produce a system context diagram, data-flow diagram, trust-boundary inventory, threat register, selected ASVS requirements, security test plan and documented residual risks.

Completion criteria

Critical assets and trust boundaries are identified, high-risk abuse cases have owners and mitigations, and each selected control has a verification method.

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.