define-security-policy

Define, review, and update SECURITY.md policy guidance for repositories and components.

Updated May 4, 2026
One-click install
npx skills add https://github.com/antstanley/skills --skill define-security-policy-antstanley
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: define-security-policy
Source: https://github.com/antstanley/skills/tree/main/plugins/security/skills/define-security-policy
Command: npx skills add https://github.com/antstanley/skills --skill define-security-policy-antstanley

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve? Repositories often lack clear security policy guidance, leaving security scanners and reviewers without context about system boundaries, threat models, reportable findings, and accepted risks. This Skill creates and maintains SECURITY.md files that tell security review tooling exactly what matters. ## Core Features & Use Cases - Policy Discovery and Resolution: Inventories existing SECURITY.md files across a repository, including nested component policies, and resolves the applicable policy chain from root to leaf. - Boundary and Threat Model Definition: Establishes system scope, trust boundaries, attacker-controlled inputs, security invariants, and severity context based on source code, tests, and prior findings. - Reviewed Drafting Workflow: Drafts structured policy sections, shows exact diffs for approval, and verifies the result after writing. - Use Case: Before running a security scan on a multi-component repository, use this Skill to write a root SECURITY.md defining which surfaces are internet-facing and which finding classes are out of scope, so scan results are triaged against real risk. ## Quick Start Ask the assistant to define a security policy for this repository, covering the system boundary, threat model, and which findings should be reportable.

Frequently Asked Questions about define-security-policy

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write a SECURITY.md policy for my repository?

Start by inventorying existing policy files, then establish the system boundary, threat model, security invariants, and reportable finding criteria from source and test evidence. Draft the policy with sections for scope, trust boundaries, severity context, and exclusions, then get owner approval before writing.

How do nested SECURITY.md files work in a monorepo?

Root and nested policies compose from root to leaf, with the policy closest to the code taking precedence when guidance conflicts. A resolver script lists all policy paths and resolves the applicable chain for a given file or directory scope.

What should a security policy include for scanner guidance?

Include system and scope, threat model and trust boundaries, security invariants that must hold, reportable findings and severity context, out-of-scope exclusions with accepted risks, and known limitations or compensating controls. Avoid empty boilerplate and sensitive finding details.

Can a SECURITY.md file suppress security findings automatically?

No. Policy files are treated as untrusted evidence that informs scope and severity but cannot authorize suppressions, commands, or edits. Material exclusion and accepted-risk decisions must be confirmed with the owner, and unverified controls are never treated as proof a finding is safe.

What are the limitations of repository security policy files?

Policies larger than 1 MiB are rejected by the resolver, and files like .github/SECURITY.md are not treated as repository-wide scanner guidance. Policies also cannot prove a control works; tests and findings only indicate intended behavior.