haimen: Skill for Claude Code

.agents/skills/security-audit/SKILL.md

security-audit is a skill for Claude Code, Codex from shenjingnan/haimen. It costs 18 tokens per session (436 once invoked), scanned A, original, MIT.

A security audit process for Rust dependencies, including checks for known vulnerabilities and license or dependency-policy problems.

In plain words
What is it for?
For running dependency audits, updating affected packages, checking formatting and compiler warnings, running tests, and handling issues that cannot be fixed by an upgrade.
Why use it?
It identifies risks in the packages recorded by Cargo and requires testing after dependency updates.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

This is shenjingnan/haimen's own configuration. It tells Claude Code and Codex how to work on haimen itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything haimen configures →

Reuse

Borrowing it

Nothing to install: this file belongs to shenjingnan/haimen. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/shenjingnan/haimen/main/.agents/skills/security-audit/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/shenjingnan/haimen

Made for: Claude Code, Codex.

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-audit

README.md
[![agentmods](https://agentmods.dev/badge/skills/shenjingnan/haimen/security-audit/github.svg)](https://agentmods.dev/skills/shenjingnan/haimen/security-audit)
Your own site
<a href="https://agentmods.dev/skills/shenjingnan/haimen/security-audit"><img src="https://agentmods.dev/badge/skills/shenjingnan/haimen/security-audit/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for security-audit

Your own site · 80×15
<a href="https://agentmods.dev/skills/shenjingnan/haimen/security-audit"><img src="https://agentmods.dev/badge/skills/shenjingnan/haimen/security-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 18 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 436 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00018 $0.00436
Opus 5 $0.00009 $0.00218
Sonnet 5 $0.00004 $0.00087
Haiku 4.5 $0.00002 $0.00044

Measured 9d ago against content hash 6f3e6f044145, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

security-audit 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 9d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/run-security-audit.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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/skills/security-audit/SKILL.md · 65 lines

What it actually says

安全审计

上下文获取

以下命令将在技能加载时自动执行,结果将注入到上下文中供分析:

  • 安全审计结果: !bash .agents/skills/security-audit/scripts/run-security-audit.sh

你的任务

根据上方注入的审计结果,按以下步骤处理:

1. 分析结果

逐项检查每个检查项的输出,判断是否存在安全问题:

  1. cargo audit — 检查 Cargo.lock 中已知漏洞的依赖
  2. cargo deny check — 检查许可协议合规性和依赖安全性

2. 修复漏洞

如果发现漏洞或过时依赖,对每个问题包依次处理:

  1. 尝试自动修复

    cargo update
    

    或手动更新到最新兼容版本:

    cargo update -p <包名>
    
  2. 验证:运行 cargo check && cargo test -- --test-threads=1

  3. 验证失败则回滚

    git checkout -- Cargo.toml Cargo.lock
    

3. 最终验证

修复完成后,确认所有检查通过:

cargo fmt --check && cargo clippy -- -D warnings && cargo test -- --test-threads=1

前置条件

cargo install cargo-audit       # 漏洞扫描
cargo install cargo-deny         # 许可/依赖检查

原则

  • 优先通过 cargo update 自动修复,无法修复时手动指定版本
  • 升级后必须通过测试验证
  • 如果某个漏洞无法通过升级修复,考虑在 deny.toml 中配置豁免(需确认风险可接受)
Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 9d ago First seen · 65 lines · 18 tokens per session scan A 6f3e6f044145

Subscribe to this mod's changes

security-audit is a skill published in the GitHub repository shenjingnan/haimen (7 stars, last pushed yesterday), licensed MIT. It adds 18 tokens to every session and 436 once invoked, about $0.0001 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-31.

Related

Other skills, from other repositories