fastgrc-openclaw 1.0.27 → 1.0.28
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/plugin.js +21 -7
- package/dist/plugin.mjs +21 -7
- package/package.json +1 -1
package/dist/plugin.js
CHANGED
|
@@ -128,13 +128,27 @@ var pluginEntry = {
|
|
|
128
128
|
return;
|
|
129
129
|
}
|
|
130
130
|
console.log("[fastgrc] Plugin registered \u2014 before_tool_call hook active");
|
|
131
|
-
const
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
131
|
+
const probeEvents = [
|
|
132
|
+
"exec",
|
|
133
|
+
"before_exec",
|
|
134
|
+
"shell",
|
|
135
|
+
"before_shell",
|
|
136
|
+
"command",
|
|
137
|
+
"before_command",
|
|
138
|
+
"run",
|
|
139
|
+
"before_run",
|
|
140
|
+
"tool_call",
|
|
141
|
+
"before_tool",
|
|
142
|
+
"action",
|
|
143
|
+
"before_action",
|
|
144
|
+
"request",
|
|
145
|
+
"before_request",
|
|
146
|
+
"call",
|
|
147
|
+
"before_call"
|
|
148
|
+
];
|
|
149
|
+
for (const evt of probeEvents) {
|
|
150
|
+
api.on(evt, (...args) => {
|
|
151
|
+
console.log(`[fastgrc:hit] ${evt}`, JSON.stringify(args[0])?.slice(0, 120));
|
|
138
152
|
});
|
|
139
153
|
}
|
|
140
154
|
api.on("before_tool_call", async (event, ctx) => {
|
package/dist/plugin.mjs
CHANGED
|
@@ -92,13 +92,27 @@ var pluginEntry = {
|
|
|
92
92
|
return;
|
|
93
93
|
}
|
|
94
94
|
console.log("[fastgrc] Plugin registered \u2014 before_tool_call hook active");
|
|
95
|
-
const
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
95
|
+
const probeEvents = [
|
|
96
|
+
"exec",
|
|
97
|
+
"before_exec",
|
|
98
|
+
"shell",
|
|
99
|
+
"before_shell",
|
|
100
|
+
"command",
|
|
101
|
+
"before_command",
|
|
102
|
+
"run",
|
|
103
|
+
"before_run",
|
|
104
|
+
"tool_call",
|
|
105
|
+
"before_tool",
|
|
106
|
+
"action",
|
|
107
|
+
"before_action",
|
|
108
|
+
"request",
|
|
109
|
+
"before_request",
|
|
110
|
+
"call",
|
|
111
|
+
"before_call"
|
|
112
|
+
];
|
|
113
|
+
for (const evt of probeEvents) {
|
|
114
|
+
api.on(evt, (...args) => {
|
|
115
|
+
console.log(`[fastgrc:hit] ${evt}`, JSON.stringify(args[0])?.slice(0, 120));
|
|
102
116
|
});
|
|
103
117
|
}
|
|
104
118
|
api.on("before_tool_call", async (event, ctx) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fastgrc-openclaw",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.28",
|
|
4
4
|
"description": "FastGRC agent compliance plugin for OpenClaw — evaluates every tool call against your policy before it executes",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.mjs",
|