How mrwadams/stride-gpt works
STRIDE GPT accepts application descriptions, diagrams, or a codebase; generates STRIDE threat findings and related security artifacts; and presents or exports the results through a CLI/REPL or Streamlit UI. The CLI’s agent workflow plans subsystems, explores code with tools, records evidence, and synthesizes findings. Other documented capabilities include DFDs, attack trees, mitigations, DREAD scoring, test cases, MITRE mappings, and Markdown, JSON, SARIF, and HTML output. Edges rely on excerpts, SOURCE INDEX references, or README statements; unsampled subsystem details are represented cautiously.
Main entry points: main.py Streamlit interface · cli.py CLI and REPL · loop.py Agent loop · llm.py LLM interface
Components 25
User interfaces
- CLI and REPL
stride_gpt/cli.py - Streamlit interface
apps/web/main.py
Agent analysis
- Subsystem planner
stride_gpt/agent/planner.py - Agent loop
stride_gpt/agent/loop.py - Code exploration tools
stride_gpt/agent/tools.py - Evidence verification
stride_gpt/agent/evidence.py - Analysis context
stride_gpt/agent/context.py - Run checkpoints
stride_gpt/agent/persistence.py
Threat modeling
- Prompt builder
stride_gpt/core/prompts/builder.py - Threat reference cards
stride_gpt/core/prompts/variants.py - LLM interface
stride_gpt/core/llm.py - STRIDE threat model
stride_gpt/core/threat_model.py - Data flow diagrams
stride_gpt/core/dfd.py - draw.io parsing
stride_gpt/core/drawio_parser.py - Attack trees
stride_gpt/core/attack_tree.py - Mitigations
stride_gpt/core/mitigations.py - DREAD scoring
stride_gpt/core/dread.py - Gherkin test cases
stride_gpt/core/test_cases.py
Results and configuration
- Analysis schemas
stride_gpt/core/schemas.py - Provider configuration
stride_gpt/config.py - Model registry
stride_gpt/models.py - Report rendering
stride_gpt/agent/report.py - HTML report
stride_gpt/agent/html_report.py
Other components
- Security practitioner
- LLM providers
Connections 32
- Security practitioner → CLI and REPL: starts analysis
README.md - Security practitioner → Streamlit interface: provides inputs
README.md - CLI and REPL → Subsystem planner: plans codebase
stride_gpt/cli.py - CLI and REPL → Agent loop: runs analysis
stride_gpt/cli.py - CLI and REPL → Run checkpoints: saves checkpoints
stride_gpt/cli.py - CLI and REPL → Report rendering: renders results
stride_gpt/cli.py - Subsystem planner → Code exploration tools: explores code
stride_gpt/agent/planner.py - Agent loop → Subsystem planner: uses plan
stride_gpt/agent/loop.py - Agent loop → Code exploration tools: dispatches tools
stride_gpt/agent/loop.py - Agent loop → Evidence verification: verifies findings
stride_gpt/agent/loop.py - Agent loop → Analysis context: uses context
stride_gpt/agent/loop.py - Agent loop → LLM interface: requests completions
stride_gpt/agent/loop.py - Agent loop → Prompt builder: builds prompts
stride_gpt/agent/loop.py - Code exploration tools → Threat reference cards: loads cards
stride_gpt/agent/tools.py - CLI and REPL → Provider configuration: loads settings
stride_gpt/cli.py - Provider configuration → Model registry: uses model catalog
stride_gpt/config.py - LLM interface → LLM providers: routes requests
stride_gpt/core/llm.py - Streamlit interface → STRIDE threat model: generates threats
apps/web/main.py - Streamlit interface → Data flow diagrams: generates DFDs
apps/web/main.py - Streamlit interface → draw.io parsing: parses diagrams
apps/web/main.py - Streamlit interface → Attack trees: generates attack trees
apps/web/main.py - Streamlit interface → Mitigations: suggests mitigations
apps/web/main.py - Streamlit interface → DREAD scoring: scores threats
apps/web/main.py - Streamlit interface → Gherkin test cases: generates cases
README.md - STRIDE threat model → LLM interface: requests generation
stride_gpt/core/threat_model.py - Data flow diagrams → LLM interface: requests generation
stride_gpt/core/dfd.py - Attack trees → LLM interface: requests generation
stride_gpt/core/attack_tree.py - Mitigations → LLM interface: requests suggestions
stride_gpt/core/mitigations.py - DREAD scoring → LLM interface: requests scoring
stride_gpt/core/dread.py - CLI and REPL → Analysis schemas: structures findings
stride_gpt/cli.py - Report rendering → HTML report: renders HTML
stride_gpt/agent/report.py - Security practitioner → Report rendering: receives exports
README.md