@goplus/agentguard 1.1.26 → 1.1.28-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/action/detectors/exec.d.ts.map +1 -1
- package/dist/action/detectors/exec.js +13 -23
- package/dist/action/detectors/exec.js.map +1 -1
- package/dist/action/index.d.ts +4 -0
- package/dist/action/index.d.ts.map +1 -1
- package/dist/action/index.js +44 -5
- package/dist/action/index.js.map +1 -1
- package/dist/adapters/claude-code.d.ts.map +1 -1
- package/dist/adapters/claude-code.js +7 -2
- package/dist/adapters/claude-code.js.map +1 -1
- package/dist/adapters/common.d.ts.map +1 -1
- package/dist/adapters/common.js +1 -0
- package/dist/adapters/common.js.map +1 -1
- package/dist/adapters/hermes.d.ts.map +1 -1
- package/dist/adapters/hermes.js +12 -2
- package/dist/adapters/hermes.js.map +1 -1
- package/dist/adapters/openclaw-plugin.d.ts.map +1 -1
- package/dist/adapters/openclaw-plugin.js +30 -10
- package/dist/adapters/openclaw-plugin.js.map +1 -1
- package/dist/adapters/openclaw.d.ts.map +1 -1
- package/dist/adapters/openclaw.js +6 -0
- package/dist/adapters/openclaw.js.map +1 -1
- package/dist/installers.js +33 -23
- package/dist/installers.js.map +1 -1
- package/dist/mcp-server.js +2 -2
- package/dist/mcp-server.js.map +1 -1
- package/dist/runtime/approvals.d.ts.map +1 -1
- package/dist/runtime/approvals.js +13 -2
- package/dist/runtime/approvals.js.map +1 -1
- package/dist/runtime/evaluator.d.ts.map +1 -1
- package/dist/runtime/evaluator.js +72 -4
- package/dist/runtime/evaluator.js.map +1 -1
- package/dist/runtime/protect.d.ts.map +1 -1
- package/dist/runtime/protect.js +38 -9
- package/dist/runtime/protect.js.map +1 -1
- package/dist/runtime/self-command.d.ts.map +1 -1
- package/dist/runtime/self-command.js +23 -1
- package/dist/runtime/self-command.js.map +1 -1
- package/dist/runtime/types.d.ts +1 -1
- package/dist/runtime/types.d.ts.map +1 -1
- package/dist/tests/action.test.js +8 -0
- package/dist/tests/action.test.js.map +1 -1
- package/dist/tests/adapter.test.js +21 -7
- package/dist/tests/adapter.test.js.map +1 -1
- package/dist/tests/cli-checkup.test.js +1 -1
- package/dist/tests/cli-checkup.test.js.map +1 -1
- package/dist/tests/cli-init.test.js +12 -2
- package/dist/tests/cli-init.test.js.map +1 -1
- package/dist/tests/installer.test.js +35 -0
- package/dist/tests/installer.test.js.map +1 -1
- package/dist/tests/integration.test.js +22 -0
- package/dist/tests/integration.test.js.map +1 -1
- package/dist/tests/runtime-cloud.test.js +241 -2
- package/dist/tests/runtime-cloud.test.js.map +1 -1
- package/dist/tests/smoke.test.js +8 -1
- package/dist/tests/smoke.test.js.map +1 -1
- package/dist/types/action.d.ts +8 -2
- package/dist/types/action.d.ts.map +1 -1
- package/docs/SECURITY-POLICY.md +1 -1
- package/docs/claude-code.md +2 -1
- package/docs/codex.md +3 -2
- package/docs/hermes.md +6 -2
- package/docs/openclaw.md +3 -2
- package/package.json +1 -1
- package/skills/agentguard/README.md +3 -2
- package/skills/agentguard/SKILL.md +3 -2
- package/skills/agentguard/hermes-hooks.yaml +4 -1
- package/skills/agentguard/scripts/action-cli.js +6 -0
- package/skills/agentguard/scripts/hermes-hook.js +1 -0
package/docs/codex.md
CHANGED
|
@@ -44,7 +44,8 @@ approval and includes an approval command:
|
|
|
44
44
|
agentguard approve --action-id act_local_... --once
|
|
45
45
|
```
|
|
46
46
|
|
|
47
|
-
|
|
48
|
-
|
|
47
|
+
Show that command to the user before running it. Run it only after the user
|
|
48
|
+
explicitly approves that exact action; do not let the agent approve its own
|
|
49
|
+
blocked command proactively. Then retry the original action once. If the action id was not visible, inspect
|
|
49
50
|
`agentguard approvals list --json`; use `agentguard approve --last --once`
|
|
50
51
|
only when there is exactly one relevant unexpired pending approval.
|
package/docs/hermes.md
CHANGED
|
@@ -29,7 +29,10 @@ hooks:
|
|
|
29
29
|
- matcher: "write_file|patch|skill_manage"
|
|
30
30
|
command: "node \"/path/to/agentguard/skills/agentguard/scripts/hermes-hook.js\""
|
|
31
31
|
timeout: 10
|
|
32
|
-
- matcher: "web_search
|
|
32
|
+
- matcher: "web_search"
|
|
33
|
+
command: "node \"/path/to/agentguard/skills/agentguard/scripts/hermes-hook.js\""
|
|
34
|
+
timeout: 10
|
|
35
|
+
- matcher: "web_extract|browser_navigate"
|
|
33
36
|
command: "node \"/path/to/agentguard/skills/agentguard/scripts/hermes-hook.js\""
|
|
34
37
|
timeout: 10
|
|
35
38
|
|
|
@@ -55,7 +58,8 @@ or set `hooks_auto_accept: true` in `~/.hermes/config.yaml`.
|
|
|
55
58
|
| `terminal`, `execute_code` | `exec_command` |
|
|
56
59
|
| `write_file`, `patch`, `skill_manage` | `write_file` |
|
|
57
60
|
| `read_file` | `read_file` |
|
|
58
|
-
| `web_search
|
|
61
|
+
| `web_search` | `web_search` |
|
|
62
|
+
| `web_extract`, `browser_navigate` | `network_request` |
|
|
59
63
|
|
|
60
64
|
## Decisions
|
|
61
65
|
|
package/docs/openclaw.md
CHANGED
|
@@ -56,8 +56,9 @@ approval. The block reason includes:
|
|
|
56
56
|
agentguard approve --action-id act_local_... --once
|
|
57
57
|
```
|
|
58
58
|
|
|
59
|
-
|
|
60
|
-
|
|
59
|
+
Show that command to the user before running it. Run it only after the user
|
|
60
|
+
explicitly approves that exact action; do not let the agent approve its own
|
|
61
|
+
blocked command proactively. Then retry the original action once. If the action id was not visible in the OpenClaw message,
|
|
61
62
|
inspect pending approvals first:
|
|
62
63
|
|
|
63
64
|
```bash
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@goplus/agentguard",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.28-beta.0",
|
|
4
4
|
"description": "GoPlus AgentGuard — Security guard for AI agents. Blocks dangerous commands, prevents data leaks, protects secrets. 20 detection rules, runtime action evaluation, trust registry.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -28,8 +28,9 @@ AI Agent Security Guard — protect your AI agents from dangerous commands, data
|
|
|
28
28
|
|
|
29
29
|
When installed from SkillHub, Hermes sees the contents of this
|
|
30
30
|
`skills/agentguard` directory first. Runtime hooks are not loaded from
|
|
31
|
-
`SKILL.md` automatically
|
|
32
|
-
|
|
31
|
+
`SKILL.md` automatically. Run `agentguard init --agent hermes` to install this
|
|
32
|
+
skill into `HERMES_HOME` or `~/.hermes` and merge the hook entries into
|
|
33
|
+
`config.yaml`. The `hermes-hooks.yaml` file remains available for manual setups.
|
|
33
34
|
|
|
34
35
|
The hook runner is `scripts/hermes-hook.js`. It uses the published
|
|
35
36
|
`@goplus/agentguard` package, so run `npm install` inside this skill directory
|
|
@@ -119,7 +119,7 @@ Connect behavior:
|
|
|
119
119
|
|
|
120
120
|
If the user writes `/agentguard cli <args...>`, execute `agentguard <args...>` directly.
|
|
121
121
|
|
|
122
|
-
When AgentGuard returns `confirm` or a block reason that includes `Approve once
|
|
122
|
+
When AgentGuard returns `confirm` or a block reason that includes `Approve once ... agentguard approve --action-id ... --once`, do not retry the protected action until the user explicitly approves. Show the exact approval command to the user before running it. Never run an approval command proactively, and never infer approval from context or from the agent's own plan. Treat user replies such as "yes", "approve", "approved", "confirm", "confirmed", "continue", "go ahead", "execute", "run it", "同意", "确认", "批准", "继续", or "执行" as explicit approval for the most recent protected action only after the user has seen the command and understands which action is being approved. After approval, run exactly the provided `agentguard approve --action-id ... --once` command, then retry the original action once. If the action id is unavailable, use `agentguard approvals list --json`; only use `agentguard approve --last --once` when there is exactly one relevant unexpired pending approval. If multiple pending approvals exist, ask the user to choose a specific action id.
|
|
123
123
|
|
|
124
124
|
Do **not** route plain `/agentguard scan`, `/agentguard action`, `/agentguard patrol`, `/agentguard trust`, `/agentguard report`, `/agentguard config`, `/agentguard checkup`, `/agentguard checkup --json`, or natural-language requests like "run agentguard checkup" through the packaged CLI. Those are this skill's higher-level workflows. Only use the packaged CLI checkup path when the user includes `--against-advisory <id>` or explicitly writes `/agentguard cli checkup ...`.
|
|
125
125
|
|
|
@@ -142,7 +142,8 @@ template at `hermes-hooks.yaml`.
|
|
|
142
142
|
| `pre_tool_call` | `terminal`, `execute_code` | `exec_command` |
|
|
143
143
|
| `pre_tool_call` | `write_file`, `patch`, `skill_manage` | `write_file` |
|
|
144
144
|
| `pre_tool_call` | `read_file` | `read_file` |
|
|
145
|
-
| `pre_tool_call` | `web_search
|
|
145
|
+
| `pre_tool_call` | `web_search` | `web_search` |
|
|
146
|
+
| `pre_tool_call` | `web_extract`, `browser_navigate`, `browser_open`, `web_open`, `open_url`, `visit_url`, `open` | `network_request` |
|
|
146
147
|
| `post_tool_call` | Same tools | Audit-only |
|
|
147
148
|
|
|
148
149
|
Hermes `pre_tool_call` supports allow/block only. If AgentGuard returns `ask`,
|
|
@@ -19,7 +19,10 @@ hooks:
|
|
|
19
19
|
- matcher: "read_file"
|
|
20
20
|
command: "node \"AGENTGUARD_SKILL_DIR/scripts/hermes-hook.js\""
|
|
21
21
|
timeout: 10
|
|
22
|
-
- matcher: "web_search
|
|
22
|
+
- matcher: "web_search"
|
|
23
|
+
command: "node \"AGENTGUARD_SKILL_DIR/scripts/hermes-hook.js\""
|
|
24
|
+
timeout: 10
|
|
25
|
+
- matcher: "web_extract|browser_navigate|browser_open|web_open|open_url|visit_url|open"
|
|
23
26
|
command: "node \"AGENTGUARD_SKILL_DIR/scripts/hermes-hook.js\""
|
|
24
27
|
timeout: 10
|
|
25
28
|
|