360 Secure SkillHub
360 安全技能中心

OC Guard

该 Skill 要求所有 OpenClaw 配置变更经 oc-guard 流程完成,先执行 plan 再 apply,高风险变更需 --confirm,禁止直接编辑宿主配置文件;执行后返回中英双语执行回执,未执行时标注未执行。附带提案模板。

edmond-ai
edmond-ai
热度 52.68
最近更新 2026-05-11 17:28:50
分类:自动化依赖:代码执行 / 读写文件应用场景:工作流 / 自动化脚本 / 模板

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add oc-guard
Metadata
name
oc_guard
description
Safe OpenClaw config planning/apply workflow with bilingual execution receipts.
metadata
{"openclaw":{"requires":{"bins":["python3","openclaw","opencode"]}}}

oc-guard Skill

Purpose

All config-changing requests must go through oc-guard. Do not directly edit ~/.openclaw/openclaw.json. When possible, invoke the bundled CLI at {baseDir}/scripts/oc-guard.py.

Hard Rules

  1. Use oc-guard plan before apply.
  2. High-risk changes require oc-guard apply --confirm.
  3. Always return execution receipt first.
  4. If command is not executed, return 【模型说明-未执行】.
  5. Never claim success without a real oc-guard receipt.

Common Commands

  • {baseDir}/scripts/oc-guard.py --help
  • {baseDir}/scripts/oc-guard.py plan "<requirement>"
  • {baseDir}/scripts/oc-guard.py apply --confirm "<requirement>"
  • {baseDir}/scripts/oc-guard.py plan --proposal <file>
  • {baseDir}/scripts/oc-guard.py apply --confirm --proposal <file>