Skip to content
Development
Skill

/gate-security

Detects leaked secrets, injection patterns, and sensitive data exposure across changed files. Uses real tooling when configured, LLM judgment for analysis. Internal gate — invoked by verify.

From plugin
specwright
1023 skills9 agents18 commands

Claude Code

$ npx -y skills add Obsidian-Owl/specwright --skill gate-security --agent claude-code

SKILL.md

gate-security.SKILL.md
name: gate-security
description: >-
  Detects leaked secrets, injection patterns, and sensitive data exposure
  across changed files. Uses real tooling when configured, LLM judgment
  for analysis. Internal gate — invoked by verify.
allowed-tools:
  - Read
  - Bash
  - Glob
  - Grep
  - Write

Gate: Security

Goal

Ensure the codebase doesn't leak secrets, introduce injection vulnerabilities, or expose sensitive data. Use real security tooling when available. Use LLM judgment for analysis that tools can't do.

Inputs

  • `{projectArtifactsRoot}/config.json` -- `commands.lint`, SAST tool config if available
  • `{repoStateRoot}/work/{selectedWork.id}/workflow.json` -- selected work unit
  • Changed files (detected via `git diff`)

Outputs

  • Evidence file at `{workDir}/evidence/security-report.md`
  • Gate status in the selected work's `workflow.json`
  • Findings shown inline with severity, location, and remediation

Constraints

**Scope (MEDIUM freedom):**

  • Focus on changed files. Use `git diff --name-only` against main branch.
  • If no changed files detected, check all files in work scope.

**Phase 1 — Detection (LOW freedom, BLOCK severity):**

  • Scan for secrets: API keys, tokens, passwords, private keys in source files.
  • Scan for .env files, credential files, or key files staged for commit.
  • Check .gitignore covers sensitive patterns.
  • If a configured SAST tool exists (e.g., `semgrep`, `eslint-plugin-security`), run it.
  • Any secret or credential found = BLOCK finding.

**Phase 2 — Analysis (HIGH freedom, WARN severity):**

  • Review changed code for injection patterns (SQL, command, XSS, path traversal).
  • Check that external data is treated as untrusted (per Constitution security practices).
  • Check that authentication/authorization patterns aren't weakened (per Constitution auth/authz practices).
  • Findings are WARN unless clearly exploitable (then BLOCK).

**Phase 3 — Logical security (HIGH freedom, WARN severity):**

  • Missing authentication (CWE-306): mutation-capable handler functions (HTTP routes, gRPC handlers, GraphQL resolvers) performing state-changing operations without any visible auth check. Only flag when auth is completely absent. Skip if no mutation-capable handler patterns detected in changed files.
  • For code-level error handling analysis (CWE-636, CWE-209), defer to gate-semantic which owns those categories with tiered tooling.
  • All Phase 3 findings are WARN. Never BLOCK.
  • Phase 3 focuses on logical control-flow; defer to Phase 2 when a finding is already captured as an injection pattern.

**Verdict (LOW freedom):**

  • Follow `protocols/evidence.md#verdict-rendering`.
  • Any BLOCK finding = gate FAIL.
  • WARN-only findings = gate WARN (passes but flagged).
  • Cite relevant Constitution practices where applicable.

Protocol References

  • `protocols/evidence.md#verdict-rendering` -- verdict rendering
  • `protocols/evidence.md` -- evidence storage
  • `protocols/state.md` -- gate status updates

Failure Modes

| Condition | Action | |-----------|--------| | No SAST tool configured | Skip tool-based detection, rely on LLM analysis | | No changed files detected | Scan all project source files | | SAST tool not installed | WARN finding, suggest installation, continue with LLM |

Read more
@obsidian-owl
Ships withspecwright

Craft quality software with AI discipline. Spec-driven development plugin for Claude Code and Opencode — quality gates, adversarial testing, and evidence capture.

1023 skills9 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
10
Star history of Obsidian-Owl/specwright on GitHub, a chart by star-history.com

Other skills on specwright.

gate-build

gate-build

Runs configured build and test commands in tiered order. Captures output as evidence per tier. Returns PASS, FAIL, WARN, or SKIP…

gate-semantic

gate-semantic

Tiered semantic analysis of changed code (rg → ast-grep → OpenGrep). Detects error-path bugs structural gates miss. Findings…

gate-spec

gate-spec

Maps every acceptance criterion from the spec to implementation evidence and test evidence. Criteria without evidence fail. The…

gate-tests

gate-tests

Audits test quality — assertion strength, boundary coverage, mock discipline, error path testing. Delegates to the tester agent…

gate-wiring

gate-wiring

Detects unused exports, orphaned files, architecture layer violations, and circular dependencies across changed files. Delegates…

sw-adopt

sw-adopt

Explicitly adopt an existing work into the current worktree after validating live ownership, stale sessions, and branch…

More skills from other plugins.

brainstorming
Auto-invoked

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…

@obra@obraInstall Skill
ask-matt

ask-matt

Ask which skill or flow fits your situation. A router over the skills in this repo.

skills2w309k
@mattpocock@mattpocockInstall Skill
accessibility
Auto-invoked

accessibility

Design, implement, and audit accessible UI to WCAG 2.2 Level AA across Web, iOS, and Android — semantic ARIA roles and labels,…

ecc2w293k
@affaan-m@affaan-mInstall Skill
compiler-commit

compiler-commit

Use when you want to verify compiler changes and commit with the correct convention. Runs tests, lint, and format, then commits…

react5d252k
@facebook@facebookInstall Skill

Questions about gate-security.

Which coding agents can use gate-security?
gate-security installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.