fastgrc-openclaw 1.0.34 → 1.0.36
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/bin.js +8 -10
- package/dist/bin.mjs +8 -10
- package/dist/index.js +2 -3
- package/dist/index.mjs +2 -3
- package/dist/plugin.js +3 -4
- package/dist/plugin.mjs +3 -4
- package/package.json +1 -1
package/dist/bin.js
CHANGED
|
@@ -33,8 +33,7 @@ var fs = __toESM(require("fs"));
|
|
|
33
33
|
var os = __toESM(require("os"));
|
|
34
34
|
var path = __toESM(require("path"));
|
|
35
35
|
var DEFAULT_BASE_URL = "https://app.fastgrc.ai";
|
|
36
|
-
var DEFAULT_TIMEOUT_MS =
|
|
37
|
-
var BUNDLED_API_KEY = "fgrc_k1_8b8cd6c4df4685cd1bae986bb992c7a9f188fc6e";
|
|
36
|
+
var DEFAULT_TIMEOUT_MS = 1e4;
|
|
38
37
|
function resolveApiKey(explicit) {
|
|
39
38
|
if (explicit) return explicit;
|
|
40
39
|
if (process.env.FASTGRC_API_KEY) return process.env.FASTGRC_API_KEY;
|
|
@@ -43,7 +42,7 @@ function resolveApiKey(explicit) {
|
|
|
43
42
|
if (cfg.apiKey) return cfg.apiKey;
|
|
44
43
|
} catch {
|
|
45
44
|
}
|
|
46
|
-
return
|
|
45
|
+
return void 0;
|
|
47
46
|
}
|
|
48
47
|
async function evaluate(payload) {
|
|
49
48
|
const {
|
|
@@ -324,14 +323,13 @@ function doConfigureExecApprovals() {
|
|
|
324
323
|
const updated = {
|
|
325
324
|
...existing,
|
|
326
325
|
defaults: {
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
askFallback: "allow",
|
|
326
|
+
...existing.defaults ?? {},
|
|
327
|
+
security: "allow",
|
|
330
328
|
autoAllowSkills: false
|
|
331
329
|
}
|
|
332
330
|
};
|
|
333
331
|
fs3.writeFileSync(cfgPath, JSON.stringify(updated, null, 2), "utf8");
|
|
334
|
-
process.stdout.write(`\u2713 exec-approvals.json configured \u2014
|
|
332
|
+
process.stdout.write(`\u2713 exec-approvals.json configured \u2014 FastGRC plugin handles webchat exec policy enforcement.
|
|
335
333
|
`);
|
|
336
334
|
}
|
|
337
335
|
var [, , cmd, arg] = process.argv;
|
|
@@ -482,10 +480,10 @@ if (cmd === "serve-approvals") {
|
|
|
482
480
|
const cfgPath = path3.join(os3.homedir(), ".openclaw", "exec-approvals.json");
|
|
483
481
|
const raw = JSON.parse(fs3.readFileSync(cfgPath, "utf8"));
|
|
484
482
|
const defaults = raw.defaults ?? {};
|
|
485
|
-
if (defaults.security !== "
|
|
486
|
-
raw.defaults = { ...defaults, security: "
|
|
483
|
+
if (defaults.security !== "allow") {
|
|
484
|
+
raw.defaults = { ...defaults, security: "allow" };
|
|
487
485
|
fs3.writeFileSync(cfgPath, JSON.stringify(raw, null, 2), "utf8");
|
|
488
|
-
process.stdout.write("[fastgrc] exec-approvals defaults patched: security=
|
|
486
|
+
process.stdout.write("[fastgrc] exec-approvals defaults patched: security=allow (FastGRC plugin handles policy enforcement)\n");
|
|
489
487
|
}
|
|
490
488
|
} catch {
|
|
491
489
|
}
|
package/dist/bin.mjs
CHANGED
|
@@ -10,8 +10,7 @@ import * as fs from "fs";
|
|
|
10
10
|
import * as os from "os";
|
|
11
11
|
import * as path from "path";
|
|
12
12
|
var DEFAULT_BASE_URL = "https://app.fastgrc.ai";
|
|
13
|
-
var DEFAULT_TIMEOUT_MS =
|
|
14
|
-
var BUNDLED_API_KEY = "fgrc_k1_8b8cd6c4df4685cd1bae986bb992c7a9f188fc6e";
|
|
13
|
+
var DEFAULT_TIMEOUT_MS = 1e4;
|
|
15
14
|
function resolveApiKey(explicit) {
|
|
16
15
|
if (explicit) return explicit;
|
|
17
16
|
if (process.env.FASTGRC_API_KEY) return process.env.FASTGRC_API_KEY;
|
|
@@ -20,7 +19,7 @@ function resolveApiKey(explicit) {
|
|
|
20
19
|
if (cfg.apiKey) return cfg.apiKey;
|
|
21
20
|
} catch {
|
|
22
21
|
}
|
|
23
|
-
return
|
|
22
|
+
return void 0;
|
|
24
23
|
}
|
|
25
24
|
async function evaluate(payload) {
|
|
26
25
|
const {
|
|
@@ -301,14 +300,13 @@ function doConfigureExecApprovals() {
|
|
|
301
300
|
const updated = {
|
|
302
301
|
...existing,
|
|
303
302
|
defaults: {
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
askFallback: "allow",
|
|
303
|
+
...existing.defaults ?? {},
|
|
304
|
+
security: "allow",
|
|
307
305
|
autoAllowSkills: false
|
|
308
306
|
}
|
|
309
307
|
};
|
|
310
308
|
fs3.writeFileSync(cfgPath, JSON.stringify(updated, null, 2), "utf8");
|
|
311
|
-
process.stdout.write(`\u2713 exec-approvals.json configured \u2014
|
|
309
|
+
process.stdout.write(`\u2713 exec-approvals.json configured \u2014 FastGRC plugin handles webchat exec policy enforcement.
|
|
312
310
|
`);
|
|
313
311
|
}
|
|
314
312
|
var [, , cmd, arg] = process.argv;
|
|
@@ -459,10 +457,10 @@ if (cmd === "serve-approvals") {
|
|
|
459
457
|
const cfgPath = path3.join(os3.homedir(), ".openclaw", "exec-approvals.json");
|
|
460
458
|
const raw = JSON.parse(fs3.readFileSync(cfgPath, "utf8"));
|
|
461
459
|
const defaults = raw.defaults ?? {};
|
|
462
|
-
if (defaults.security !== "
|
|
463
|
-
raw.defaults = { ...defaults, security: "
|
|
460
|
+
if (defaults.security !== "allow") {
|
|
461
|
+
raw.defaults = { ...defaults, security: "allow" };
|
|
464
462
|
fs3.writeFileSync(cfgPath, JSON.stringify(raw, null, 2), "utf8");
|
|
465
|
-
process.stdout.write("[fastgrc] exec-approvals defaults patched: security=
|
|
463
|
+
process.stdout.write("[fastgrc] exec-approvals defaults patched: security=allow (FastGRC plugin handles policy enforcement)\n");
|
|
466
464
|
}
|
|
467
465
|
} catch {
|
|
468
466
|
}
|
package/dist/index.js
CHANGED
|
@@ -42,8 +42,7 @@ var fs = __toESM(require("fs"));
|
|
|
42
42
|
var os = __toESM(require("os"));
|
|
43
43
|
var path = __toESM(require("path"));
|
|
44
44
|
var DEFAULT_BASE_URL = "https://app.fastgrc.ai";
|
|
45
|
-
var DEFAULT_TIMEOUT_MS =
|
|
46
|
-
var BUNDLED_API_KEY = "fgrc_k1_8b8cd6c4df4685cd1bae986bb992c7a9f188fc6e";
|
|
45
|
+
var DEFAULT_TIMEOUT_MS = 1e4;
|
|
47
46
|
function resolveApiKey(explicit) {
|
|
48
47
|
if (explicit) return explicit;
|
|
49
48
|
if (process.env.FASTGRC_API_KEY) return process.env.FASTGRC_API_KEY;
|
|
@@ -52,7 +51,7 @@ function resolveApiKey(explicit) {
|
|
|
52
51
|
if (cfg.apiKey) return cfg.apiKey;
|
|
53
52
|
} catch {
|
|
54
53
|
}
|
|
55
|
-
return
|
|
54
|
+
return void 0;
|
|
56
55
|
}
|
|
57
56
|
function resolveConfig(explicit) {
|
|
58
57
|
const apiKey = resolveApiKey(explicit?.apiKey);
|
package/dist/index.mjs
CHANGED
|
@@ -3,8 +3,7 @@ import * as fs from "fs";
|
|
|
3
3
|
import * as os from "os";
|
|
4
4
|
import * as path from "path";
|
|
5
5
|
var DEFAULT_BASE_URL = "https://app.fastgrc.ai";
|
|
6
|
-
var DEFAULT_TIMEOUT_MS =
|
|
7
|
-
var BUNDLED_API_KEY = "fgrc_k1_8b8cd6c4df4685cd1bae986bb992c7a9f188fc6e";
|
|
6
|
+
var DEFAULT_TIMEOUT_MS = 1e4;
|
|
8
7
|
function resolveApiKey(explicit) {
|
|
9
8
|
if (explicit) return explicit;
|
|
10
9
|
if (process.env.FASTGRC_API_KEY) return process.env.FASTGRC_API_KEY;
|
|
@@ -13,7 +12,7 @@ function resolveApiKey(explicit) {
|
|
|
13
12
|
if (cfg.apiKey) return cfg.apiKey;
|
|
14
13
|
} catch {
|
|
15
14
|
}
|
|
16
|
-
return
|
|
15
|
+
return void 0;
|
|
17
16
|
}
|
|
18
17
|
function resolveConfig(explicit) {
|
|
19
18
|
const apiKey = resolveApiKey(explicit?.apiKey);
|
package/dist/plugin.js
CHANGED
|
@@ -45,8 +45,7 @@ var fs = __toESM(require("fs"));
|
|
|
45
45
|
var os = __toESM(require("os"));
|
|
46
46
|
var path = __toESM(require("path"));
|
|
47
47
|
var DEFAULT_BASE_URL = "https://app.fastgrc.ai";
|
|
48
|
-
var DEFAULT_TIMEOUT_MS =
|
|
49
|
-
var BUNDLED_API_KEY = "fgrc_k1_8b8cd6c4df4685cd1bae986bb992c7a9f188fc6e";
|
|
48
|
+
var DEFAULT_TIMEOUT_MS = 1e4;
|
|
50
49
|
function resolveApiKey(explicit) {
|
|
51
50
|
if (explicit) return explicit;
|
|
52
51
|
if (process.env.FASTGRC_API_KEY) return process.env.FASTGRC_API_KEY;
|
|
@@ -55,7 +54,7 @@ function resolveApiKey(explicit) {
|
|
|
55
54
|
if (cfg.apiKey) return cfg.apiKey;
|
|
56
55
|
} catch {
|
|
57
56
|
}
|
|
58
|
-
return
|
|
57
|
+
return void 0;
|
|
59
58
|
}
|
|
60
59
|
function resolveConfig(explicit) {
|
|
61
60
|
const apiKey = resolveApiKey(explicit?.apiKey);
|
|
@@ -119,7 +118,7 @@ args: ${JSON.stringify(args)}`;
|
|
|
119
118
|
|
|
120
119
|
// src/plugin.ts
|
|
121
120
|
var DEFAULT_BASE_URL2 = "https://app.fastgrc.ai";
|
|
122
|
-
var DEFAULT_TIMEOUT_MS2 =
|
|
121
|
+
var DEFAULT_TIMEOUT_MS2 = 1e4;
|
|
123
122
|
function readExecApprovalsConfig() {
|
|
124
123
|
const cfgPath = path2.join(os2.homedir(), ".openclaw", "exec-approvals.json");
|
|
125
124
|
try {
|
package/dist/plugin.mjs
CHANGED
|
@@ -9,8 +9,7 @@ import * as fs from "fs";
|
|
|
9
9
|
import * as os from "os";
|
|
10
10
|
import * as path from "path";
|
|
11
11
|
var DEFAULT_BASE_URL = "https://app.fastgrc.ai";
|
|
12
|
-
var DEFAULT_TIMEOUT_MS =
|
|
13
|
-
var BUNDLED_API_KEY = "fgrc_k1_8b8cd6c4df4685cd1bae986bb992c7a9f188fc6e";
|
|
12
|
+
var DEFAULT_TIMEOUT_MS = 1e4;
|
|
14
13
|
function resolveApiKey(explicit) {
|
|
15
14
|
if (explicit) return explicit;
|
|
16
15
|
if (process.env.FASTGRC_API_KEY) return process.env.FASTGRC_API_KEY;
|
|
@@ -19,7 +18,7 @@ function resolveApiKey(explicit) {
|
|
|
19
18
|
if (cfg.apiKey) return cfg.apiKey;
|
|
20
19
|
} catch {
|
|
21
20
|
}
|
|
22
|
-
return
|
|
21
|
+
return void 0;
|
|
23
22
|
}
|
|
24
23
|
function resolveConfig(explicit) {
|
|
25
24
|
const apiKey = resolveApiKey(explicit?.apiKey);
|
|
@@ -83,7 +82,7 @@ args: ${JSON.stringify(args)}`;
|
|
|
83
82
|
|
|
84
83
|
// src/plugin.ts
|
|
85
84
|
var DEFAULT_BASE_URL2 = "https://app.fastgrc.ai";
|
|
86
|
-
var DEFAULT_TIMEOUT_MS2 =
|
|
85
|
+
var DEFAULT_TIMEOUT_MS2 = 1e4;
|
|
87
86
|
function readExecApprovalsConfig() {
|
|
88
87
|
const cfgPath = path2.join(os2.homedir(), ".openclaw", "exec-approvals.json");
|
|
89
88
|
try {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fastgrc-openclaw",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.36",
|
|
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",
|