security

A command for auditing a target project for security vulnerabilities, adapting the checks to whether it is a library, command-line tool, web app, or service. It covers issues such as exposed secrets, missing access controls, and absent rate limits where relevant.

In plain words
What is it for?
Use it to check for leaked credentials, unsafe data access, missing rate limits, and other applicable security problems in a codebase.
Why use it?
It gives a repeatable way to look for common security weaknesses without reporting categories that do not apply to the target.

Command

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 commands/hamr0/liteagents/security
Clone the repo
git clone --depth 1 https://github.com/hamr0/liteagents
Per session 7 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,086 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.00007 $0.01086
Opus 5 $0.00003 $0.00543
Sonnet 5 $0.00001 $0.00217
Haiku 4.5 $0.00001 $0.00109

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

Security

Grade A, and why

security 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.

packages/ampcode/commands/security.md · 87 lines

How it starts

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

Audit $ARGUMENTS for security vulnerabilities. Adapt scope to what the target actually is — a library, CLI, web app, and service won't all have every category. Skip what genuinely doesn't apply; never invent findings to fill a section.

The recurring six (check every project, where applicable)

These show up in nearly every quickly-built app regardless of stack:

  1. Secrets in the repo. Tokens / API keys / .env files committed to tracked files or anywhere in git history. Verify .env is gitignored and only a value-less .env.example is tracked; scan history (git log -p, git grep) for leaked keys. Secrets must load from env / a secret store at runtime — never hardcoded, never logged.
  2. Data-access authorization (tenant isolation). Every record read or written must be scoped to the requesting principal — via DB-level rules (RLS / row policies) and/or application-layer ownership checks. Flag any query that trusts a client-supplied id without an ownership or role gate, and any table/collection with a policy that's too broad or missing.
  3. Rate limiting. Every externally reachable endpoint and abuse-prone inbound path is bounded — including authenticated mutation/write routes, not just the obvious public GETs. Note any unbounded route.
  4. Error handling past the happy path. Third-party / IO / DB failures are caught; nothing fails silently; no internal detail (stack traces, queries, secrets) leaks to the client. Background/async work has its own catch.
  5. Authorization beyond authentication (IDOR / privilege). "Logged in" is not "allowed to do this". Confirm ownership AND role/permission checks on every state-changing or privileged action. Mentally swap an id in a request — does it return 403, or does it leak/modify another user's data?
  6. Inefficient data access (N+1 / unindexed). Queries inside loops, per-render repeated calls, missing indexes on filtered/joined columns. Correct but falls over under load — a real availability risk.

Read the full file on GitHub · 87 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 · 87 lines · 7 tokens per session scan A 7e61c5cece49

Subscribe to this mod's changes

security is a command published in the GitHub repository hamr0/liteagents (22 stars, last pushed 3d ago), licensed Apache-2.0. It adds 7 tokens to every session and 1,086 once invoked, about $0.0000 per session on Opus 5. 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-30.