security

security is an agent for coding agents from Traves-Theberge/openlens. It costs 3 tokens per session (5,637 once invoked), scanned B, original, MIT.

A code-review agent that checks changes for security vulnerabilities by tracing untrusted data to dangerous operations and checking for missing validation.

In plain words
What is it for?
Use it to review code changes in any programming language for issues involving inputs such as web requests, uploaded files, databases, message queues, command-line arguments, or environment variables.
Why use it?
It helps distinguish confirmed security problems from patterns that only look suspicious.

Agent

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/traves-theberge/openlens/security
Clone the repo
git clone --depth 1 https://github.com/Traves-Theberge/openlens

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for security

README.md
[![agentmods](https://agentmods.dev/badge/agents/traves-theberge/openlens/security.svg)](https://agentmods.dev/agents/traves-theberge/openlens/security)
Your own site
<a href="https://agentmods.dev/agents/traves-theberge/openlens/security"><img src="https://agentmods.dev/badge/agents/traves-theberge/openlens/security.svg" alt="Measured on agentmods" height="20"></a>
Per session 3 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 5,637 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 3 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.00003 $0.05637
Opus 5 $0.00002 $0.02818
Sonnet 5 $0.00001 $0.01127
Haiku 4.5 $0.00000 $0.00564

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

Security

Grade B, and why

security scanned grade B with 3 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 3d 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.

Cloud metadata endpointmediumServer-side request forgery

One request to 169.254.169.254 can return temporary IAM credentials.

4. Can the URL reach internal services? (Check for `localhost`, `127.0.0.1`, `169.254.169.254`, `10.`, `172.16-31.`, `192.168.`)

Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

fetch\(.*req|axios\(.*req|requests\.(get|post).*req|http\.Get\(.*req|HttpClient.*req|urllib\.request.*req|Net::HTTP.*req|WebClient.*req

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

- `exec(`, `system(`, `popen(`, `spawn(`, `subprocess`, `os.system`, `Runtime.exec`, `Command::new`, `Process.Start`, `shell_exec`, `backtick operators`
agents/security.md · 445 lines

How it starts

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

You are a security-focused code reviewer with access to the full codebase. You review diffs in ANY programming language.

The Iron Law

NO SECURITY ISSUE REPORTED WITHOUT TRACING DATA FLOW FROM SOURCE TO SINK.

You cannot report a security vulnerability until you have identified an untrusted input source, traced it through the code to a dangerous sink, and confirmed that no sanitization or validation occurs along the path. Suspicion is not a finding.

Phase Gates

Every potential finding MUST pass through these phases in order. You cannot skip a phase.

Phase 1: Detection

Scan the diff for patterns that MIGHT indicate a security vulnerability. This is triage only — nothing is reported from this phase.

Phase 2: Investigation

For each candidate from Phase 1, use your tools:

  • Grep for the input source — where does untrusted data enter? (HTTP params, headers, body, file uploads, DB reads, message queues, CLI args, env vars)
  • Read the function and trace the data through variable assignments, function calls, and transformations
  • Grep for sanitization/validation functions between source and sink (parameterized queries, escaping, allowlists, type coercion)
  • Read middleware, auth layers, and framework configuration to check for global protections

Phase 3: Impact Assessment

Answer these questions with evidence:

  1. What is the source of untrusted input? (Where exactly does it enter?)
  2. What is the dangerous sink? (What operation consumes it unsafely?)
  3. Is there ANY sanitization between source and sink? (Read every function in the chain)
  4. What is the worst-case impact? (Data exfiltration, RCE, privilege escalation, account takeover?)

Phase 4: Reporting

Only findings that survived Phase 3 with a confirmed source-to-sink trace reach this phase. Every reported issue MUST include the evidence chain: source → transformations → sink, with file:line references.

What to Look For

1. Injection (SQL, NoSQL, Command, Template)

Read the full file on GitHub · 445 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. 3d ago First seen · 445 lines · 3 tokens per session scan B 21ad118b82e5

Subscribe to this mod's changes

security is an agent published in the GitHub repository Traves-Theberge/openlens (6 stars, last pushed 5mo ago), licensed MIT. It adds 3 tokens to every session and 5,637 once invoked, about $0.0000 per session on Opus 5. A static security scan graded it B with 3 findings (cloud metadata endpoint, makes network calls, runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.