Claude Guard — Development skill for Claude Code
Claude Code 启动门禁与运行看门狗 / Startup guard and dry-run watchdog for official Claude Code.
How to install Claude Guard
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open wetlink/claude-guard and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Claude Guard does
Claude Code 启动门禁与运行看门狗 / Startup guard and dry-run watchdog for official Claude Code.
Alternatives in Development
- Microsandbox — Open-source self-hosted MicroVM sandboxes with sub-200ms startup, hardware-level isolation via libkrun 5k ★
- Claude Code Rust — 🚀 Rust 全量重构的 Claude Code - 性能提升 2.5x,体积减少 97% High-performance Rust implementation of Claude Code with 2.5x f 1.4k ★
- Update Scaffold — Check for and apply myPKA scaffold framework updates safely 296 ★
README
Claude 守护
[](https://github.com/wetlink/claude-guard/actions/workflows/check.yml) [](LICENSE)
Claude 守护是一套 Claude Code 双通道版本与启动策略。它让官方 Claude 通道保持严格、可审计和固定版本,同时允许本机 CC Switch 通道独立跟进较新的 Claude Code 工程能力。两条通道共享客户端形态,但不共享 profile 和路由。
当前版本:`2.1.3`(完整版本历史见文末[版本历史](#版本历史))
本项目不是 Anthropic 或 Claude Code 官方项目。
v2.1 稳定升级架构
| 入口 | 用途 | Profile | 请求目标 | 客户端策略 | 生命周期策略 |
|---|---|---|---|---|---|
claude / claude-official |
官方 Claude 模型 | 显式固定的稳定官方 profile | api.anthropic.com |
固定经过验包的版本 | TUI 内后台任务可用,脱离终端 fail-closed |
claude-cc |
本机 CC Switch 兼容链路 | 独立 CC Switch profile | 固定 loopback endpoint | 独立跟进经过验包的新版本 | 保留工程能力 |
核心边界:
- 官方通道不读取 CC Switch 的 base URL 或 token;
v2.0.1默认沿用原稳定 profile、settings 和 session,只替换经过验包的客户端内核。 - CC Switch 通道不加载官方 profile 或文件凭据。macOS Keychain 是系统级边界, 因此最终以实际 endpoint 和进程身份验证为准,不把“文件不存在”当作唯一证明。
- 官方通道继续检查出口 IP、HTTP CONNECT、TLS issuer、IPv6 和生命周期策略。
- 官方通道允许 Anthropic 官方功能开关下发,以支持内建
/design等分阶段能力; 自动更新、错误上报、反馈命令和会话质量问卷仍分别关闭。 - CC Switch 通道检查客户端身份、本机 endpoint、监听进程路径、签名、Bundle ID、 应用版本、profile 路由和 credentials 污染;它不会把第三方兼容链路描述成 Anthropic 官方链路。
- 两条通道都关闭客户端自动更新。任何版本切换都必须先验版本、SHA-256、 macOS 签章和回归测试,再修改固定指针。
- CC Switch 通道有意保留 background agent、plugin、hook 等工程能力,因此它 不受官方通道的前台 fail-closed 生命周期保护;后台任务应由使用者明确启动和 回收。
- CC Switch 通道关闭 telemetry、OTel exporter、非必要网络流量和自动更新, 但不关闭核心推理、工具、agent、plugin 或 hook。
发布 `v2.0.0` 时,[Claude Code 验证版本](https://github.com/anthropics/claude-code/releases/tag/v2.1.220) 是 `2.1.220`。这只是本次发布的验证矩阵,不代表仓库永远把某个版本写死为 “最新”。
客户端切换不会中断已经运行的旧进程,只在下一次执行 `claude` 时生效。
为什么必须保留 2.1.170
`2.1.170` 是本项目的重要历史回退基线:
- 它记录了双通道架构建立前已经长期实际运行过的客户端行为。
- 新版本发生 TUI、TLS、session resume、插件、background process 或 gateway 兼容性回归时,可以用它区分“客户端变化”和“网络/服务端变化”。
- 它适合作为短期诊断与回滚参照,不应被自动更新程序覆盖,也不应在升级时删除。
这里的“重要”不等于 Anthropic 官方安全认证,也不表示 `2.1.170` 永远优于新版本。 它是
Related Skills
Ceiling Guard
Local plan-window meter and observe-only watchdog for Claude Code, Codex, and Grok CLI
Ownerrez Rate Setter Skill
A Claude Code skill for changing OwnerRez + PriceLabs nightly rates safely: write guard that fails closed, dry
Grounded Research Skill
Anti-hallucination research skill for Claude Code — admits uncertainty, extracts direct quotes before analysis
Cc Tg Watchdog
Claude Code + Telegram watchdog script for 24/7 VPS uptime
Claude Code API Watchdog
Auto-recover Claude Code sessions stuck on transient API errors. Outer-loop watchdog for unattended tmux Claud
Lord Claude
Five Claude Code skills that delegate sub-tasks to rival CLIs — Codex, Gemini (via Antigravity), Grok, and Com
Related Agents
Katago Integrator
KataGo sidecar integration with IPC, watchdog, and difficulty system
Library Spec Guardian
Independent quality and non-negotiable watchdog for the library-spec-negotiation skill. Reviews each topic res
Deal Watchdog
Stops a target list from quietly rotting — re-reads expired signals, catches companies acquired since classifi