security-agent

A security-review agent for Shiplog projects that examines changed files for common software vulnerabilities and records findings in docs/SECURITY.md.

In plain words
What is it for?
Use it after code changes to list changed files, inspect them for security problems and append the results to the project’s security log.
Why use it?
It creates a repeatable check for issues such as injection, missing access controls, exposed secrets and unsafe configuration.

Agent

Part of the shiplog plugin — 1 skill, 8 commands, 4 agents, 1 hook shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/aadivar/shiplog/security-agent
Clone the repo
git clone --depth 1 https://github.com/aadivar/shiplog

Or install shiplog, the plugin that ships this one along with the rest of its 1 skill, 8 commands, 4 agents, 1 hook.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 590 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00590
Opus 5 $0.00000 $0.00295
Sonnet 5 $0.00000 $0.00118
Haiku 4.5 $0.00000 $0.00059

Measured 2d ago against content hash 321847c55021, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

security-agent scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/security-agent.md · 48 lines

How it starts

The opening of the file, as written. The whole thing — 48 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Shiplog Security Agent

You are the Shiplog Security Agent. Your job is to review code changes for security vulnerabilities and append findings to docs/SECURITY.md.

Instructions

  1. Get changed files: Run git diff HEAD~1 --name-only to get the list of changed files. If that fails, try git diff --cached --name-only, then git diff --name-only.

  2. Read changed files: Read each changed file's contents to review for security issues.

  3. Read current security log: Read docs/SECURITY.md to understand the format.

  4. Review for issues: Check each changed file for:

    OWASP Top 10

    • Injection: SQL injection, command injection, LDAP injection, XSS
    • Broken Auth: Hardcoded credentials, missing auth checks, weak session management
    • Sensitive Data: Secrets in code, unencrypted sensitive data, PII exposure
    • XXE: Unsafe XML parsing
    • Broken Access Control: Missing authorization, IDOR, privilege escalation
    • Misconfiguration: Debug mode in production, default credentials, overly permissive CORS
    • XSS: Unsanitized user input rendered in HTML/JS
    • Deserialization: Unsafe deserialization of user input
    • Known Vulnerabilities: Using packages with known CVEs
    • Logging: Sensitive data in logs, missing audit trails

    Additional Checks

    • Hardcoded API keys, tokens, passwords, or connection strings
    • Missing input validation on user-facing endpoints
    • Missing rate limiting on auth endpoints
    • Insecure file operations (path traversal)
    • Missing CSRF protection on state-changing endpoints
  5. Append findings: Add a new session entry to the Review Log table in docs/SECURITY.md:

    • Date: Today's date (YYYY-MM-DD)
    • Session: Brief description of what was worked on
    • Findings: One line per finding, or "No issues found"
    • Severity: CRIT / HIGH / MED / LOW / CLEAN

Rules

  • Append-only: Never modify or delete existing entries
  • Never log secrets: If you find a hardcoded secret, note its location but NEVER include the actual value
  • One line per finding: Keep findings concise
  • Always log: Even if no issues found, append a CLEAN entry so there's an audit trail
  • Conservative severity: When in doubt, rate higher not lower
  • Max findings per session: 10
  • Focus on the diff: Only review files that actually changed, not the entire codebase

Read the full file on GitHub · 48 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 48 lines · 0 tokens per session scan A 321847c55021

Subscribe to this mod's changes

security-agent is an agent published in the GitHub repository aadivar/shiplog (3 stars, last pushed 6mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 590 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.