Introducing The Sweep: OX’s New Live Security Research Series
Register Now
Breaking: The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Read the Report
Are you exposed? Connect your apps in minutes.
Scan your apps free

@mokuyoaxis/agent-guard

Latest version: v0.3.4

Overview

Last scanned
1 Dec 2026
Published
1 Dec 2026
npm package Publisher: mokuyoaxis
25 Stars
4 Forks
15 Versions
2.8K Downloads
Python Repo language

Scan summary

@mokuyoaxis/agent-guard was last scanned on 1 Dec 2026 at version 0.3.4. Risk score 0 of 100. No malicious behavior was detected.

  • Releases: 15 versions; the latest 2 were published within 4 days (28 Nov – 1 Dec 2026).
  • Findings: No rules fired in version 0.3.4.
  • Downloads: 2,760 downloads.

Versions

15 versions published
Versions and the rules that fired in each
VersionPublishedStatus
0.3.4 LATEST 1 Dec 2026 No rules fired
0.3.3 28 Nov 2026 No rules fired
0.3.2 22 Nov 2026 No rules fired
0.3.1 21 Nov 2026 Not shown
0.2.9 9 Nov 2026 Not shown

No rules fired in 0.3.4

Findings

Findings for v0.3.4. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.

The score describes 0.3.4; other versions have their own rules, not their own score.

README

The publisher’s own README, as collected from the registry.

编码 Agent 经常在可预见的地方出错:一条范围过宽的 rm 清空未提交的改动,一段调试日志把凭据带进提交或提示词,或者宿主工具升级后旧 hook 悄悄失效。Agent Guard 基于零依赖的共享 Python Core(3.9+)与可选宿主适配层,为编码 Agent 提供确定性的事务级可恢复保护、多通道无原文外发防护、L0 成对校准与工作区只读体检。

[!IMPORTANT] 负责接入本项目的 AI Agent: 修改宿主配置或编写桥接前,请先阅读适配要求、接入流程以及对应宿主适配指南。核实实际宿主与版本号并查阅其官方 hook 文档,只如实报告已验证的覆盖范围——不能仅凭“Skill 已安装”或“配置已复制”就判断防护已生效。

核心能力一览

能力模块 核心功能 指南与契约
Delete-guard 受支持破坏性删除前的隔离保全与 Git 快照;内联脚本删除双重锚定拦截;Cleanup Copilot 盘点与获准维护任务;按工作区生效的容量、速率/重复限制、保护路径与受控可再生模式;按需只读隔离区空间计量(--measure-storage)、只读恢复预览、跨回执归并与选择性按路径恢复、手动 GC 与可选本地 MCP 工具(默认 15 工具/Codex 16 工具) Skill 与 CLI · Cleanup Copilot · 删除限制 · 统一只读查询 · 恢复与 GC · MCP 工具 · MCP doctor
Exfil-guard 无原文扫描待外发文本中的凭据格式、凭据源引用与宿主标识路径;基于计划验证的安全脱敏与可选元数据审计;脱敏分页只读入口(agent-guard-safe-read 与 MCP safe_read);不暴露标量值的 JSON / .env / TOML 配置结构视图(safe_view);基于独立白名单策略的本地标量配置编辑(agent-guard-config-edit);文件导出预检(agent-guard-exfil-export)、本地 Git Hook、MCP 工具与可选 Bash 预检 Skill 与 CLI · 脱敏只读 · 受控配置编辑 · 检测规则与导出 · 安全配置视图 · Git Hook
Guard-lab 与 Doctor 在一次性夹具中运行四项回环对照与 13 对 L0 生命周期校准(lifecycle-calibration),投放非秘密合成标记并执行关闭/开启防护的配对比较;只读 agent-guard-doctor workspace 巡检删除与配置编辑策略、.claude/settings.local.json Git/工作树暴露、Skill 链接、Git Hook 与持久载体隐形 Unicode 走私 Lab 指南 · 生命周期校准 · 工作区体检 · 四控制示例

Core 与适配器构成上述模块的共享底座。若事故已经发生,可辅助使用 recovery-audit 从尚存的 Git、会话与缓存记录中审计并重建工作区。

工作机制与能力边界

  • 行为引导与真实拦截分离: Skill 为 Agent 提供操作纪律,自动拦截则依赖宿主实际加载的兼容 hook(如 PreToolUse 或 DSH 插件)及其覆盖的工具路径。可选本地 MCP 适配器暴露显式维护工具,不会拦截绕过它的原生命令或编辑器操作。
  • 工程可靠性基建,而非 OS 沙箱: Agent Guard 与 Agent 运行在同一操作系统权限级别。它的目标是兜住常见失误——工作目录错位、命令误展开、意外外发——而非隔离同权限的恶意进程(详见威胁模型)。
  • 受支持破坏性操作不确定即收紧(Fail-closed): 各链路共用统一决策协议(ALLOW · SANITIZE · RELOCATE · SNAPSHOT · ASK · BLOCK,聚合优先级 BLOCK > ASK > RELOCATE/SNAPSHOT > SANITIZE > ALLOW)。当识别到受支持的破坏性操作(或无法解析的引号/语法),且无法静态确定其目标或效果时——例如包含未解析变量、命令替换、间接 Shell 解释器或经标准输入传入目标列表的删除命令——系统拒绝猜测并返回 BLOCK;未命中受支持破坏性模式的普通命令(例如输出 $PWD 或 $(pwd))仍返回 ALLOW_NOOP(详见策略契约)。
  • 额度按工作区根目录生效: Delete-guard 的预算、速率限制与保护路径通过工作区根目录的 .agent-guard/delete-policy.json 统一管理;同一仓库内的应用和库共用该策略,未设置字段沿用内置默认值(详见工作区配置)。

安装与版本

Core 需要 Python 3.9+ 与 Git(示例默认使用 POSIX Shell)。可选本地 MCP 适配器需要 Python 3.10+ 及单独安装的固定版本 MCP SDK。

将当前稳定版 0.3.4 安装到长期保留的用户目录:

npm install --prefix /absolute/path/to/agent-guard-install @mokuyoaxis/agent-guard@0.3.4

安装后的包根目录为 /absolute/path/to/agent-guard-install/node_modules/@mokuyoaxis/agent-guard(请保留 @mokuyoaxis/ 作用域)。也可以直接使用源码仓库:

git clone https://github.com/mokuyoaxis/agent-guard.git
cd agent-guard

具体发行资产可在 GitHub Release (0.3.4) 与 npm (0.3.4) 查看。离线 tarball 安装、版本升级及扩展运行要求(如可选 DSH 读取原型需 Node 22、TOML safe_view 与 Kimi TOML 辅助需 Python 3.11+、agent-guard-exfil-export/safe_read 需 POSIX 描述符、agent-guard-config-edit 需支持 xattr 检测的 Linux)见入门指南。

版本 核心变更
0.3.4 L0 lifecycle-calibration 扩充至 13 对/26 项(selective_restore_storage、safe_read;Windows 适用 11 对);只读 doctor workspace 新增 .claude/settings.local.json 检查(checks.claude_local_settings);二进制与链接安全的 manifest_coverage 贯通 restore list、preview、MCP transactions(partial: true)与直接 restore 执行 fail-closed;Cleanup 目标角色报错对齐、恢复交接指南、Cursor CLI 2026.11.22-e9042b2 stdio MCP 证据与双语 README 11.28 徽标收口
0.3.3 Exfil-guard 脱敏分页只读入口(agent-guard-safe-read 及默认第 15/Codex 第 16 项 MCP 工具 safe_read)与操作者白名单标量配置编辑 CLI(agent-guard-config-edit,覆盖 JSON 与单行 .env,17 项 npm CLI 入口、7 项 exfil-guard Skill 入口);Delete-guard 按需隔离区空间计量(status --view overview --measure-storage 含已验 Top-10 排行)与跨历史回执归并的选择性恢复(restore --path / MCP paths);跨平台 doctor workspace 新增 config_edit_policy 核验;双语 README 收录 11.28 纪念日特别版徽标
0.3.2 Exfil-guard TOML 安全视图、可选外发审计、3 项 MCP 工具、本地 Git Hook、八类现代凭据、agent-guard-exfil-export 与 opt-in Bash 预检;Delete-guard protect/regenerable 策略 CLI 与整树敏感源守卫、只读 restore.py preview 及 MCP restore_preview(14 默认/15 Codex)、内联脚本删除拦截、Windows PowerShell 交接格式化;L0 成对 lifecycle-calibration、只读 agent-guard-doctor workspace(含隐形 Unicode 载体走私检测)
0.3.1 Cleanup 终端确认屏重构(永久删除置顶、可读/精确容量、超 20 根目录汇总与只读清单)、CLI 唯一短前缀 ID、多目标 --targets-file 引导、精确 txid 与 gc.py --task 清理、跨文件系统暂存恢复与 manual_review_items、agent-guard-delete-policy 额度 CLI、三套 Skill 安装器
0.3.0 审核后批量维护工作流(保存明确目标计划、操作者单次批准、Agent 按任务 ID 执行与查询)、可选强制隔离、linked Skill 安装器、可选 Codex 原生确认表单
0.2.9 Cleanup 只读目录概况(--discover)与选定范围计量(--measure)、两项只读 MCP 工具、计划扫描性能优化
0.2.8 本地 MCP 连接诊断(doctor.py mcp)与协议中断恢复核验
0.2.7 Cleanup Copilot 计划、共享删除准入控制(容量、预算、速率/重复限制、保护路径)、可选本地 MCP 服务端
0.2.6 Kimi 可选 Stop 恢复反馈与 doctor 检查、DSH Lab 预检诊断、DSH 0.2.1-alpha.4 默认删除适配、Kimi 2.3.0 Bash profile
0.2.5 / 0.2.4 早期稳定版(显式存储/GC/NOOP 反馈、持久迁移记录与 trash_index 查询)
0.2.5-rc3 / 0.2.4-hotfix.1 显式选择的独立通道(对应 npm rc 与 hotfix 标签,不覆盖稳定版 latest);0.2.4-hotfix.1 仅在 0.2.4 上回补隔离区控制路径保护

说明:自 0.2.7 起引入的删除准入限制可能拒绝此前版本能够直接放行的批量或无保护删除。从旧版本升级时需显式执行安装或更新步骤,系统不会自动迁移既有全局 Skill 或宿主配置。

核心工作流

1. 可恢复删除与审核维护(Delete-guard)

在受保护的工作区根目录调用安装包或源码目录下的脚本:

python3 /absolute/path/to/agent-guard/skills/delete-guard/scripts/safe_delete.py src/old_module.py --dry-run
python3 /absolute/path/to/agent-guard/skills/delete-guard/scripts/safe_delete.py src/old_module.py
python3 /absolute/path/to/agent-guard/skills/delete-guard/scripts/restore.py list
python3 /absolute/path/to/agent-guard/skills/delete-guard/scripts/restore.py '<txid>'

执行与恢复契约:

OX Radar and Response Center

Find threats in your stack.

OX Radar can check high-priority threats, like critical package CVEs, against your context.

Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.

Where it’s listed

The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).

  • npm @mokuyoaxis/agent-guard

References

The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.

Powered by Read the latest findings

Scan your whole stack

Group 1261154050 1
Group 1261154050
 

From OX Research Newsroom

Cry2Wolf: How to Tell a Real Bug from a Nothingburger
AI & VibeSec

Cry2Wolf: Not Every Branded Bug Deserves a Fire Drill

CVE

Java4Shell (CVE-2026-114938): Easy to Crash, Hard to Exploit — Less Than 0.12% of JVMs Estimated at Risk of RCE

Copy of Template Design OX Blog (3)
Research

Ruby2Shell: Ruby Memory Corruption Flaws Expose Applications to Remote Code Execution, But is it an Actual Risk?

Frame 2085668439 (1)
Group 1261154229