feat: add security-first enforcement layer with threat-model-anchored verification
Adds /gsd:secure-phase command and gsd-security-auditor agent as a threat-model-anchored security gate parallel to Nyquist validation. New files: - agents/gsd-security-auditor.md — verifies PLAN.md threat mitigations exist in implemented code; SECURED/OPEN_THREATS/ESCALATE returns - commands/gsd/secure-phase.md — retroactive command, mirrors validate-phase - get-shit-done/workflows/secure-phase.md — enforcing gate: threats_open > 0 blocks phase advancement; accepted risks log prevents resurface - get-shit-done/templates/SECURITY.md — per-phase threat register artifact Modified: - config.json — security_enforcement (absent=enabled), security_asvs_level, security_block_on parallel to nyquist_validation pattern - VALIDATION.md — Threat Ref + Secure Behavior columns in verification map - gsd-planner.md — <threat_model> block in PLAN.md format + quality gate - gsd-executor.md — Rule 2 threat model reference + ## Threat Flags scan - gsd-phase-researcher.md — ## Security Domain mandatory research section - plan-phase.md — step 5.55 Security Threat Model Gate - execute-phase.md — security gate announcement in aggregate step - verify-work.md — /gsd:secure-phase surfaced in completion routing Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -222,6 +222,8 @@ Priority: Context7 > Exa (verified) > Firecrawl (official docs) > Official GitHu
|
||||
- [ ] Confidence levels assigned honestly
|
||||
- [ ] "What might I have missed?" review completed
|
||||
- [ ] **If rename/refactor phase:** Runtime State Inventory completed — all 5 categories answered explicitly (not left blank)
|
||||
- [ ] Security domain included (or `security_enforcement: false` confirmed)
|
||||
- [ ] ASVS categories verified against phase tech stack
|
||||
|
||||
</verification_protocol>
|
||||
|
||||
@@ -393,6 +395,27 @@ Verified patterns from official sources:
|
||||
|
||||
*(If no gaps: "None — existing test infrastructure covers all phase requirements")*
|
||||
|
||||
## Security Domain
|
||||
|
||||
> Required when `security_enforcement` is enabled (absent = enabled). Omit only if explicitly `false` in config.
|
||||
|
||||
### Applicable ASVS Categories
|
||||
|
||||
| ASVS Category | Applies | Standard Control |
|
||||
|---------------|---------|-----------------|
|
||||
| V2 Authentication | {yes/no} | {library or pattern} |
|
||||
| V3 Session Management | {yes/no} | {library or pattern} |
|
||||
| V4 Access Control | {yes/no} | {library or pattern} |
|
||||
| V5 Input Validation | yes | {e.g., zod / joi / pydantic} |
|
||||
| V6 Cryptography | {yes/no} | {library — never hand-roll} |
|
||||
|
||||
### Known Threat Patterns for {stack}
|
||||
|
||||
| Pattern | STRIDE | Standard Mitigation |
|
||||
|---------|--------|---------------------|
|
||||
| {e.g., SQL injection} | Tampering | {parameterized queries / ORM} |
|
||||
| {pattern} | {category} | {mitigation} |
|
||||
|
||||
## Sources
|
||||
|
||||
### Primary (HIGH confidence)
|
||||
|
||||
Reference in New Issue
Block a user