Marketplace

security-architecture

Design security architectures with threat modeling and zero trust

$ 安裝

git clone https://github.com/pluginagentmarketplace/custom-plugin-software-architect /tmp/custom-plugin-software-architect && cp -r /tmp/custom-plugin-software-architect/skills/security-architecture ~/.claude/skills/custom-plugin-software-architect

// tip: Run this command in your terminal to install the skill


name: security-architecture description: Design security architectures with threat modeling and zero trust version: "2.0.0" sasmp_version: "1.3.0" bonded_agent: 05-security-architecture bond_type: PRIMARY_BOND last_updated: "2025-01"

Security Architecture Skill

Purpose

Design and validate security architectures through threat modeling (STRIDE), zero trust implementation, and compliance alignment for enterprise systems.


Parameters

ParameterTypeRequiredValidationDefault
systemstringmin: 50 chars-
analysis_typeenumthreat_model|zero_trust|compliance|reviewthreat_model
threat_contextenuminternal|external|bothboth
data_classificationenumpublic|internal|confidential|restrictedinternal
compliance_frameworksarrayvalid frameworks[]

Execution Flow

┌──────────────────────────────────────────────────────────┐
│ 1. VALIDATE: Check system description                     │
│ 2. CLASSIFY: Data and asset classification                │
│ 3. MODEL: Threat modeling (STRIDE)                        │
│ 4. DESIGN: Security controls                              │
│ 5. ALIGN: Map to compliance requirements                  │
│ 6. ASSESS: Risk assessment                                │
│ 7. DOCUMENT: Return security architecture                 │
└──────────────────────────────────────────────────────────┘

Retry Logic

ErrorRetryBackoffMax Attempts
VALIDATION_ERRORNo-1
COMPLIANCE_LOOKUP_ERRORYes1s2
THREAT_DB_ERRORYes2s3

Logging & Observability

log_points:
  - event: analysis_started
    level: info
    data: [analysis_type, threat_context]
  - event: threats_identified
    level: info
    data: [threat_count, high_severity_count]
  - event: compliance_gaps_found
    level: warn
    data: [framework, gap_count]

metrics:
  - name: analyses_performed
    type: counter
    labels: [analysis_type]
  - name: threats_identified
    type: counter
    labels: [severity]
  - name: compliance_score
    type: gauge

Error Handling

Error CodeDescriptionRecovery
E301Missing system contextRequest architecture details
E302Unknown compliance frameworkShow supported frameworks
E303Incomplete threat modelFlag missing threat categories
E304Conflicting controlsHighlight conflicts

Unit Test Template

test_cases:
  - name: "STRIDE threat model"
    input:
      system: "Web application handling customer PII"
      analysis_type: "threat_model"
      data_classification: "confidential"
    expected:
      has_threats: true
      stride_categories: 6
      has_mitigations: true

  - name: "Zero trust design"
    input:
      system: "Corporate application for remote workers"
      analysis_type: "zero_trust"
    expected:
      has_identity_model: true
      has_access_policies: true
      has_micro_segmentation: true

  - name: "Compliance gap analysis"
    input:
      system: "Healthcare patient portal"
      analysis_type: "compliance"
      compliance_frameworks: ["HIPAA"]
    expected:
      has_requirements: true
      has_gap_analysis: true

Troubleshooting

Common Issues

SymptomRoot CauseResolution
Incomplete threat modelMissing attack surfaceMap all entry points
Compliance gapsMissing controlsMap controls to requirements
Over-restrictive policiesSecurity vs usabilityBalance with risk acceptance

Debug Checklist

□ Is system context complete?
□ Are all data flows documented?
□ Are all entry points identified?
□ Are threats mapped to mitigations?
□ Is compliance framework valid?

STRIDE Quick Reference

ThreatMitigation Category
SpoofingAuthentication
TamperingIntegrity controls
RepudiationLogging/Audit
Information DisclosureEncryption
Denial of ServiceAvailability
Elevation of PrivilegeAuthorization

Integration

ComponentTriggerData Flow
Agent 05Security requestReceives system, returns threat model
Agent 04Cloud securityProvides security requirements

Quality Standards

  • Defense in depth: Multiple control layers
  • Privacy by design: Data minimization
  • Least privilege: Minimal access

Version History

VersionDateChanges
2.0.02025-01Production-grade: STRIDE, compliance mapping
1.0.02024-12Initial release