做什么
构建,审查,或硬化AI代理,LLM应用,RAG,工具调用,编码代理,以及具有安全逐一默认控制的代理工作流程. 触发于即时注射,工具权限,批准,AI数据处理,RAG中毒,可观察性,或安全CI. 不要用于非AI应用程序.
技能库 智客分类:安全测试 secure-ai-agent-coding
构建,审查,或硬化AI代理,LLM应用,RAG,工具调用,编码代理,以及具有安全逐一默认控制的代理工作流程. 触发于即时注射,工具权限,批准,AI数据处理,RAG中毒,可观察性,或安全CI. 不要用于非AI应用程序.
官方网址:skills.sh
先看中文介绍;官方 description 原文单独保留,不改写 SKILL.md。
构建,审查,或硬化AI代理,LLM应用,RAG,工具调用,编码代理,以及具有安全逐一默认控制的代理工作流程. 触发于即时注射,工具权限,批准,AI数据处理,RAG中毒,可观察性,或安全CI. 不要用于非AI应用程序.
官方 description 未单独写出 Use when。按规范,代理会在用户任务与这段 description 的关键词匹配时激活本技能。
按 Agent Skills 渐进披露:启动时只加载 name 与 description(约 100 token);任务匹配后才读入整份 SKILL.md 正文;scripts/、references/、assets/ 仅在需要时再读。 本文件正文结构:secure-ai-agent-coding、Decision Tree、Quick Reference、Core Workflow、Control Router、Operational Scripts。 其中含规范建议的小节:分步指令。
文件分析:除 SKILL.md 外,正文引用了 references/implementation-patterns.md、references/controls.md、scripts/scan_patterns.py、references/review-workflow.md、references/governance.md、references/threat-model.md,属于带资源的技能包,这些文件按需再读。
Build, review, or harden AI agents, LLM apps, RAG, tool-calling, coding agents, and agentic workflows with secure-by-default controls. Trigger on prompt injection, tool permissions, approvals, AI data handling, RAG poisoning, observability, or safety CI. Do NOT use for non-AI appsec.
secure-ai-agent-codingDecision TreeQuick ReferenceCore WorkflowControl RouterOperational ScriptsSource ScopeGotchas
兼容:Requires: python3 for optional local pattern scanning. No external packages required.
来源分类:skills.sh agent-skill
namesecure-ai-agent-codingdescriptioncompatibilityreferences/implementation-patterns.mdreferences/controls.mdscripts/scan_patterns.pyreferences/review-workflow.mdreferences/governance.mdreferences/threat-model.mdreferences/gotchas.md以下路径提取自原文;文件是否齐全请以来源仓库中的完整目录为准。
具体调用语法与可用工具以目标 Agent 客户端为准。 查看调用机制说明 ↗
先选择目标 Agent 和安装范围,保留技能包的附属文件,安装后检查客户端能否发现该技能。
该技能引用了附属文件,请从来源获取完整目录;仅复制 SKILL.md 可能缺少依赖。
复制安装指令给支持 Agent Skills 的代理,确认其中的目标目录与客户端匹配。
把 Agent Skill「secure-ai-agent-coding」安装到我的项目:SKILL.md 原文与官方 description 见 https://zicq.com/zh/skills/skl-9139e96f125bf85e-%E5%AE%89%E5%85%A8-Ai-%E4%BB%A3%E7%90%86%E7%BC%96%E7%A0%81.html 请存为 .cursor/skills/secure-ai-agent-coding/SKILL.md 或 .claude/skills/secure-ai-agent-coding/SKILL.md,frontmatter 的 name 与 description 保持原样,不要改写。 该技能还带 scripts/、references/、assets/ 等文件,请从 https://github.com/jpcaparas/skills 取完整目录,不要只建一个 SKILL.md。
需要 Node.js 与 npx。先查看仓库技能列表,确认实际名称。
npx skills add 'https://github.com/jpcaparas/skills' --list
npx skills add 'https://github.com/jpcaparas/skills' --skill 'secure-ai-agent-coding'
CLI 会交互选择目标 Agent,默认安装到项目;用户级安装使用 -g。先通过查看命令核对仓库内容,再用 npx skills list 检查已安装技能。
name: secure-ai-agent-coding description: "Build, review, or harden AI agents, LLM apps, RAG, tool-calling, coding agents, and agentic workflows with secure-by-default controls. Trigger on prompt injection, tool permissions, approvals, AI data handling, RAG poisoning, observability, or safety CI. Do NOT use for non-AI appsec." compatibility: "Requires: python3 for optional local pattern scanning. No external packages required." metadata: version: "1.0.0" short-description: "Secure AI agent coding review and hardening" openclaw: category: "development" requires: bins: [python3] references:
Build or review AI agents and LLM applications so their blast radius stays small, their behavior is auditable, and high-impact actions require explicit control.
What is the user asking for?
references/implementation-patterns.md, then apply references/controls.md before writing integration code.scripts/scan_patterns.py /path/to/project --json if source code is available, then read references/review-workflow.md.references/implementation-patterns.md and require allowlisted tools, per-action authorization, rate limits, rollback, and approval gates.references/governance.md and references/threat-model.md before designing prompts or retrieval flows.references/review-workflow.md and references/gotchas.md, preserve logs, stop autonomous actions, and recover from a known safe state.| Task | Action |
|------|--------|
| Find likely dangerous patterns | Run python3 scripts/scan_patterns.py /path/to/project |
| Classify risk | Tier each agent action by impact, reversibility, data sensitivity, and external side effects |
| Protect prompts | Separate instructions from untrusted data; validate, delimit, and minimize context |
| Protect tool calls | Use explicit allowlists, scoped credentials, per-action authorization, and rate limits |
| Protect users and data | Classify data, minimize disclosure, redact logs, verify consent, and avoid raw production data in test systems |
| Protect downstream systems | Validate structured model output before using it in code, SQL, shell, APIs, or UI rendering |
| Protect production | Add monitoring, anomaly alerts, safety regression tests, rollback plans, and incident response steps |
| Review exceptions | Document why a control does not apply, who accepted the risk, and when it expires |
| Area | Load |
|------|------|
| End-to-end review process, severity, report format | references/review-workflow.md |
| Control catalog and evidence checklist | references/controls.md |
| Copyable implementation patterns | references/implementation-patterns.md |
| AI-specific threat scenarios and risk tiers | references/threat-model.md |
| Inventory, consent, model updates, lifecycle, and operations | references/governance.md |
| Common failure modes and reviewer traps | references/gotchas.md |
| Source conversion notes and scope exclusions | references/source-policy.md |
Use scripts/scan_patterns.py as a first-pass heuristic scanner, not as proof of safety.
python3 scripts/scan_patterns.py /path/to/project
python3 scripts/scan_patterns.py /path/to/project --json --fail-on high
The scanner intentionally favors review prompts over automated verdicts. Treat findings as places to inspect.
This skill adapts the engineering-applicable controls from Galdren's "Secure AI & Agent Coding Policy" into an agent skill. It keeps the parts that can drive code review, architecture decisions, local checks, and production hardening. It leaves legal judgment, organization-specific approvals, and physical security as prompts to involve the right team rather than pretending a coding skill can resolve them.
安全测试
人工智能特工的安全第一技能审查。 在安装来自 ClawdHub, GitHub 或其他来源的任何技能之前使用 。 检查红旗,许可范围,可疑图案.
安全测试
MoltGuard——由OpenGuardrails担任OpenClaw保安. 安装 MoltGuard 以保护你和你的人类免受迅速注射、数据过滤和恶意命令的影响。 资料来源:https://github.com/openguardrails/openguardrails/tre…
安全测试
用于审查安全漏洞代码,实施认证流,审计OWASP Top 10,配置CORS/CSP头,处理秘密,输入验证,SQL注射预防,XSS保护,或任何与安全相关的代码审查.
安全测试
安装任何AI代理技能前的安全审查协议. 红旗侦取入证盗取,疏通密码,放出. 风险分类:低/中/高/高。 编制结构化审查报告。 不先运行此功能, 绝不安装不信任的技能 .