@vincemakes/kiso-subagent-ext 0.40.5 → 0.40.7
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/kiso-subagent.mjs +19 -2
- package/package.json +2 -2
package/dist/kiso-subagent.mjs
CHANGED
|
@@ -392,9 +392,14 @@ function delegationConfig() {
|
|
|
392
392
|
try {
|
|
393
393
|
const raw = process.env.KISO_DELEGATION_CONFIG_JSON;
|
|
394
394
|
const parsed = raw === undefined ? {} : JSON.parse(raw);
|
|
395
|
-
return {
|
|
395
|
+
return {
|
|
396
|
+
checks: parsed.checks ?? {},
|
|
397
|
+
evaluators: Array.isArray(parsed.evaluators) ? parsed.evaluators.filter((p) => typeof p === "string") : [],
|
|
398
|
+
profiles: parsed.profiles ?? [],
|
|
399
|
+
sessionsDir: typeof parsed.sessionsDir === "string" && parsed.sessionsDir !== "" ? parsed.sessionsDir : undefined,
|
|
400
|
+
};
|
|
396
401
|
} catch {
|
|
397
|
-
return { checks: {}, profiles: [], sessionsDir: undefined };
|
|
402
|
+
return { checks: {}, evaluators: [], profiles: [], sessionsDir: undefined };
|
|
398
403
|
}
|
|
399
404
|
}
|
|
400
405
|
|
|
@@ -428,6 +433,18 @@ export function validateTask(task, cfg, parentCwd, manifestDir) {
|
|
|
428
433
|
const real = realpathSync(a.evaluator);
|
|
429
434
|
const project = realpathSync(parentCwd);
|
|
430
435
|
if (real === project || real.startsWith(project + sep)) return `refused: evaluator must live OUTSIDE the project (the child could reach it): ${a.evaluator}`;
|
|
436
|
+
// CS-1 (0.40.7): only a script the USER listed. The model chooses
|
|
437
|
+
// the task, so an unlisted path could be an interpreter
|
|
438
|
+
// (`/usr/bin/python3 <worktree>`) running code the child wrote —
|
|
439
|
+
// outside the shell tool and everything that reads shell lines.
|
|
440
|
+
const listed = (cfg.evaluators ?? []).some((p) => {
|
|
441
|
+
try {
|
|
442
|
+
return realpathSync(p) === real;
|
|
443
|
+
} catch {
|
|
444
|
+
return false;
|
|
445
|
+
}
|
|
446
|
+
});
|
|
447
|
+
if (!listed) return `refused: ${a.evaluator} is not a configured evaluator — the user lists evaluator scripts in "evaluators" in the kiso config (configured: ${(cfg.evaluators ?? []).join(", ") || "none"}); use a configured check instead, or omit acceptance`;
|
|
431
448
|
}
|
|
432
449
|
}
|
|
433
450
|
if (task.model !== undefined && !cfg.profiles.includes(task.model)) return `refused: unknown model profile ${JSON.stringify(task.model)} (configured: ${cfg.profiles.join(", ") || "none"})`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vincemakes/kiso-subagent-ext",
|
|
3
|
-
"version": "0.40.
|
|
3
|
+
"version": "0.40.7",
|
|
4
4
|
"description": "kiso official subagent extension \u2014 child kiso processes with role policies, kernel untouched",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"test": "vitest run"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@vincemakes/kiso-core": "0.40.
|
|
26
|
+
"@vincemakes/kiso-core": "0.40.7",
|
|
27
27
|
"@types/node": "^26.1.2",
|
|
28
28
|
"typescript": "^5.7.2",
|
|
29
29
|
"vitest": "^3.0.0"
|