@intutic/shared-types 2.0.0 → 2.2.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/api-contracts.d.ts +3 -3
- package/dist/billing.d.ts +0 -21
- package/dist/billing.d.ts.map +1 -1
- package/dist/enums.d.ts +10 -1
- package/dist/enums.d.ts.map +1 -1
- package/dist/enums.js +10 -1
- package/dist/enums.js.map +1 -1
- package/dist/errors.d.ts +11 -1
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +11 -1
- package/dist/errors.js.map +1 -1
- package/dist/governanceCoverage.d.ts +2 -2
- package/dist/governanceCoverage.js +2 -2
- package/dist/guardrailIr.d.ts +70 -2
- package/dist/guardrailIr.d.ts.map +1 -1
- package/dist/guardrailIr.js +106 -3
- package/dist/guardrailIr.js.map +1 -1
- package/dist/guardrailRender.d.ts +13 -1
- package/dist/guardrailRender.d.ts.map +1 -1
- package/dist/guardrailRender.js +10 -0
- package/dist/guardrailRender.js.map +1 -1
- package/dist/index.d.ts +11 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +29 -4
- package/dist/index.js.map +1 -1
- package/dist/intelligence.d.ts +0 -1
- package/dist/intelligence.d.ts.map +1 -1
- package/dist/intelligence.js.map +1 -1
- package/dist/modelCatalog.d.ts +19 -15
- package/dist/modelCatalog.d.ts.map +1 -1
- package/dist/modelCatalog.generated.d.ts +344 -61
- package/dist/modelCatalog.generated.d.ts.map +1 -1
- package/dist/modelCatalog.generated.js +52 -31
- package/dist/modelCatalog.generated.js.map +1 -1
- package/dist/modelCatalog.js +33 -32
- package/dist/modelCatalog.js.map +1 -1
- package/dist/notifications.d.ts +37 -3
- package/dist/notifications.d.ts.map +1 -1
- package/dist/policyGuardrails.d.ts +11 -4
- package/dist/policyGuardrails.d.ts.map +1 -1
- package/dist/policyGuardrails.js +7 -1
- package/dist/policyGuardrails.js.map +1 -1
- package/dist/providerVerification.d.ts.map +1 -1
- package/dist/providerVerification.js +10 -0
- package/dist/providerVerification.js.map +1 -1
- package/dist/providers.d.ts +13 -3
- package/dist/providers.d.ts.map +1 -1
- package/dist/providers.js +24 -3
- package/dist/providers.js.map +1 -1
- package/dist/proxyBaseUrls.d.ts +32 -0
- package/dist/proxyBaseUrls.d.ts.map +1 -0
- package/dist/proxyBaseUrls.js +57 -0
- package/dist/proxyBaseUrls.js.map +1 -0
- package/dist/scriptScan.d.ts +36 -0
- package/dist/scriptScan.d.ts.map +1 -1
- package/dist/scriptScan.js +11 -1
- package/dist/scriptScan.js.map +1 -1
- package/dist/skillScan.d.ts +41 -13
- package/dist/skillScan.d.ts.map +1 -1
- package/dist/skillScan.js +56 -13
- package/dist/skillScan.js.map +1 -1
- package/dist/sop.d.ts +19 -6
- package/dist/sop.d.ts.map +1 -1
- package/dist/sop.js +8 -7
- package/dist/sop.js.map +1 -1
- package/dist/ssoGroupClearance.d.ts +103 -0
- package/dist/ssoGroupClearance.d.ts.map +1 -0
- package/dist/ssoGroupClearance.js +157 -0
- package/dist/ssoGroupClearance.js.map +1 -0
- package/dist/sync.d.ts +53 -21
- package/dist/sync.d.ts.map +1 -1
- package/dist/sync.js +3 -2
- package/dist/sync.js.map +1 -1
- package/dist/workspaceSettings.d.ts +68 -24
- package/dist/workspaceSettings.d.ts.map +1 -1
- package/dist/workspaceSettings.js +19 -4
- package/dist/workspaceSettings.js.map +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* SSO-group tool clearance — the one evaluator.
|
|
4
|
+
*
|
|
5
|
+
* A workspace's `sso_group_policy` names high-risk tools, the IdP groups that
|
|
6
|
+
* clear them, and tools that only an on-behalf-of token may call. These places
|
|
7
|
+
* decide a tool call against it: the control plane's hook gate
|
|
8
|
+
* (`resolveSsoGroupPrivilege`), the MCP proxy, the Rust proxy's response gate,
|
|
9
|
+
* and — through the policy snapshot the sync daemon compiles with this
|
|
10
|
+
* function — every harness gate. `@intutic/gate`, `intutic-clawde` and the Rust
|
|
11
|
+
* proxy (`packages/proxy/src/sso_groups.rs`) cannot depend on this package, so
|
|
12
|
+
* they carry ports; `fixtures/sso-group-clearance-vectors.json` holds all of
|
|
13
|
+
* them to the same answers.
|
|
14
|
+
*
|
|
15
|
+
* The algorithm, in order:
|
|
16
|
+
* 1. no policy → GRANTED
|
|
17
|
+
* 2. tool on `requireOboFor` → REQUIRES_OBO (a gate has no OBO token,
|
|
18
|
+
* so every gate refuses it)
|
|
19
|
+
* 3. tool not on `highRiskTools` → GRANTED
|
|
20
|
+
* 4. member's groups unknown → DENIED (fail closed; never "granted")
|
|
21
|
+
* 5. member holds a `requiredGroups` → GRANTED
|
|
22
|
+
* 6. otherwise → DENIED
|
|
23
|
+
*
|
|
24
|
+
* Names and groups match exactly — no case folding, no patterns — because
|
|
25
|
+
* that is what the server has always done and a gate that matched more loosely
|
|
26
|
+
* would refuse calls the server allows.
|
|
27
|
+
*
|
|
28
|
+
* @module
|
|
29
|
+
*/
|
|
30
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
31
|
+
exports.SSO_GROUP_RECORD_TAG = exports.SsoGroupPolicySchema = void 0;
|
|
32
|
+
exports.parseSsoGroupPolicy = parseSsoGroupPolicy;
|
|
33
|
+
exports.ssoGroupRuleId = ssoGroupRuleId;
|
|
34
|
+
exports.evaluateSsoGroupClearance = evaluateSsoGroupClearance;
|
|
35
|
+
exports.encodeSsoGroupRecord = encodeSsoGroupRecord;
|
|
36
|
+
exports.decodeSsoGroupRecord = decodeSsoGroupRecord;
|
|
37
|
+
const zod_1 = require("zod");
|
|
38
|
+
function stringList(value) {
|
|
39
|
+
return Array.isArray(value) ? value.filter((v) => typeof v === 'string') : [];
|
|
40
|
+
}
|
|
41
|
+
/** One tool or group name: matched exactly, so no trimming happens anywhere. */
|
|
42
|
+
const SsoGroupNameSchema = zod_1.z.string().min(1).max(256);
|
|
43
|
+
const SsoGroupNameListSchema = zod_1.z.array(SsoGroupNameSchema).max(500).default([]);
|
|
44
|
+
/**
|
|
45
|
+
* The shape of `sso_group_policy` — the one definition. The settings PUT
|
|
46
|
+
* validates a write against it (and refuses anything else with a 400 naming
|
|
47
|
+
* the field), and {@link parseSsoGroupPolicy} reads a stored value through it.
|
|
48
|
+
* Each list is optional on write and defaults to empty.
|
|
49
|
+
*/
|
|
50
|
+
exports.SsoGroupPolicySchema = zod_1.z
|
|
51
|
+
.object({
|
|
52
|
+
highRiskTools: SsoGroupNameListSchema,
|
|
53
|
+
requiredGroups: SsoGroupNameListSchema,
|
|
54
|
+
requireOboFor: SsoGroupNameListSchema,
|
|
55
|
+
})
|
|
56
|
+
.strict();
|
|
57
|
+
/**
|
|
58
|
+
* Reads a stored `sso_group_policy`. A value the settings route wrote passes
|
|
59
|
+
* {@link SsoGroupPolicySchema} as it is. One that reached the row some other
|
|
60
|
+
* way is still read rather than dropped: null only when there is no policy
|
|
61
|
+
* object at all; a wrong-typed list reads as empty and non-string entries are
|
|
62
|
+
* dropped, so a malformed `requiredGroups` leaves every high-risk tool denied
|
|
63
|
+
* rather than the whole policy silently gone.
|
|
64
|
+
*/
|
|
65
|
+
function parseSsoGroupPolicy(value) {
|
|
66
|
+
const valid = exports.SsoGroupPolicySchema.safeParse(value);
|
|
67
|
+
if (valid.success)
|
|
68
|
+
return valid.data;
|
|
69
|
+
if (typeof value !== 'object' || value === null || Array.isArray(value))
|
|
70
|
+
return null;
|
|
71
|
+
const p = value;
|
|
72
|
+
const policy = {};
|
|
73
|
+
for (const key of Object.keys(exports.SsoGroupPolicySchema.shape)) {
|
|
74
|
+
policy[key] = stringList(p[key]);
|
|
75
|
+
}
|
|
76
|
+
return policy;
|
|
77
|
+
}
|
|
78
|
+
/** A rule id that survives `ruleIdFromReason` (`[A-Za-z0-9_.:-]`). */
|
|
79
|
+
function ssoGroupRuleId(kind, toolName) {
|
|
80
|
+
return `sso_group.${kind}.${toolName.replace(/[^A-Za-z0-9_.:-]/g, '_')}`;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Decides one tool call. `toolNames` is every name the call goes by — the MCP
|
|
84
|
+
* proxy sees `create_issue` where a harness hook sees
|
|
85
|
+
* `mcp__github__create_issue` — and a policy entry naming any of them applies.
|
|
86
|
+
* `memberGroups` null means the caller does not know the member's groups.
|
|
87
|
+
*/
|
|
88
|
+
function evaluateSsoGroupClearance(policy, toolNames, memberGroups) {
|
|
89
|
+
if (!policy)
|
|
90
|
+
return { clearance: 'GRANTED', ruleId: null, reason: '' };
|
|
91
|
+
const names = typeof toolNames === 'string' ? [toolNames] : toolNames;
|
|
92
|
+
const obo = names.find((n) => policy.requireOboFor.includes(n));
|
|
93
|
+
if (obo !== undefined) {
|
|
94
|
+
return {
|
|
95
|
+
clearance: 'REQUIRES_OBO',
|
|
96
|
+
ruleId: ssoGroupRuleId('require_obo', obo),
|
|
97
|
+
reason: `SSO group policy: ${obo} is on-behalf-of only, and a tool-call gate has no OBO token to present`,
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
const risky = names.find((n) => policy.highRiskTools.includes(n));
|
|
101
|
+
if (risky === undefined)
|
|
102
|
+
return { clearance: 'GRANTED', ruleId: null, reason: '' };
|
|
103
|
+
if (memberGroups && policy.requiredGroups.some((g) => memberGroups.includes(g))) {
|
|
104
|
+
return { clearance: 'GRANTED', ruleId: null, reason: '' };
|
|
105
|
+
}
|
|
106
|
+
const groups = policy.requiredGroups.length > 0 ? policy.requiredGroups.join(', ') : '(none configured)';
|
|
107
|
+
return {
|
|
108
|
+
clearance: 'DENIED',
|
|
109
|
+
ruleId: ssoGroupRuleId('high_risk', risky),
|
|
110
|
+
reason: memberGroups
|
|
111
|
+
? `SSO group policy: ${risky} requires one of the SSO groups ${groups}, and this member holds none of them`
|
|
112
|
+
: `SSO group policy: ${risky} requires one of the SSO groups ${groups}, and this gate does not know the member's groups`,
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* First column of the record's line in `policy-snapshot.rules`.
|
|
117
|
+
*
|
|
118
|
+
* The record is a data line, not a `#` header, on purpose: every gate's digest
|
|
119
|
+
* covers exactly the non-`#` lines, so the member's groups are inside the
|
|
120
|
+
* integrity check every deployed gate already performs, and an edited group
|
|
121
|
+
* list fails it. Two columns, so every rule parser (which needs six) skips it.
|
|
122
|
+
*/
|
|
123
|
+
exports.SSO_GROUP_RECORD_TAG = '@sso_groups';
|
|
124
|
+
function toBase64(text) {
|
|
125
|
+
let binary = '';
|
|
126
|
+
for (const byte of new TextEncoder().encode(text))
|
|
127
|
+
binary += String.fromCharCode(byte);
|
|
128
|
+
return btoa(binary);
|
|
129
|
+
}
|
|
130
|
+
function fromBase64(b64) {
|
|
131
|
+
return new TextDecoder('utf-8', { fatal: true }).decode(Uint8Array.from(atob(b64), (c) => c.charCodeAt(0)));
|
|
132
|
+
}
|
|
133
|
+
/** The record as one `.rules` line: the tag, a tab, base64 of its JSON. */
|
|
134
|
+
function encodeSsoGroupRecord(record) {
|
|
135
|
+
return `${exports.SSO_GROUP_RECORD_TAG}\t${toBase64(JSON.stringify(record))}`;
|
|
136
|
+
}
|
|
137
|
+
/** Reads a record line back; null for any other line or a damaged one. */
|
|
138
|
+
function decodeSsoGroupRecord(line) {
|
|
139
|
+
const [tag, b64, ...rest] = line.split('\t');
|
|
140
|
+
if (tag !== exports.SSO_GROUP_RECORD_TAG || !b64 || rest.length > 0)
|
|
141
|
+
return null;
|
|
142
|
+
try {
|
|
143
|
+
const raw = JSON.parse(fromBase64(b64));
|
|
144
|
+
const policy = parseSsoGroupPolicy(raw['policy']);
|
|
145
|
+
if (!policy || typeof raw['issuedAt'] !== 'string')
|
|
146
|
+
return null;
|
|
147
|
+
const m = raw['member'];
|
|
148
|
+
const member = m && typeof m === 'object' && typeof m['memberId'] === 'string'
|
|
149
|
+
? { memberId: m['memberId'], ssoGroups: stringList(m['ssoGroups']) }
|
|
150
|
+
: null;
|
|
151
|
+
return { policy, member, issuedAt: raw['issuedAt'] };
|
|
152
|
+
}
|
|
153
|
+
catch {
|
|
154
|
+
return null;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
//# sourceMappingURL=ssoGroupClearance.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ssoGroupClearance.js","sourceRoot":"","sources":["../src/ssoGroupClearance.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;;;AA4CH,kDAUC;AAGD,wCAEC;AAQD,8DA+BC;AAsCD,oDAEC;AAGD,oDAgBC;AA3JD,6BAAuB;AAYvB,SAAS,UAAU,CAAC,KAAc;IAChC,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAe,EAAE,CAAC,OAAO,CAAC,KAAK,QAAQ,CAAC,CAAC,CAAC,CAAC,EAAE,CAAA;AAC5F,CAAC;AAED,gFAAgF;AAChF,MAAM,kBAAkB,GAAG,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAA;AACrD,MAAM,sBAAsB,GAAG,OAAC,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC,CAAA;AAE/E;;;;;GAKG;AACU,QAAA,oBAAoB,GAAG,OAAC;KAClC,MAAM,CAAC;IACN,aAAa,EAAE,sBAAsB;IACrC,cAAc,EAAE,sBAAsB;IACtC,aAAa,EAAE,sBAAsB;CACtC,CAAC;KACD,MAAM,EAAE,CAAA;AAEX;;;;;;;GAOG;AACH,SAAgB,mBAAmB,CAAC,KAAc;IAChD,MAAM,KAAK,GAAG,4BAAoB,CAAC,SAAS,CAAC,KAAK,CAAC,CAAA;IACnD,IAAI,KAAK,CAAC,OAAO;QAAE,OAAO,KAAK,CAAC,IAAI,CAAA;IACpC,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AAU,CAAC,EAAE,SAAS,EAAE,UAAU,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,EAAE;YACpE,CAAC,CAAC,IAAI,CAAA;QACV,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,CAAC,UAAU,CAAC,EAAE,CAAA;IACtD,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAA;IACb,CAAC;AACH,CAAC"}
|
package/dist/sync.d.ts
CHANGED
|
@@ -144,6 +144,13 @@ export interface IntuticConfig {
|
|
|
144
144
|
* restart without waiting for the first fetch.
|
|
145
145
|
*/
|
|
146
146
|
settings?: WorkspaceSettings;
|
|
147
|
+
/**
|
|
148
|
+
* Harnesses `intutic disconnect --harness` took out. They are also removed
|
|
149
|
+
* from `harnesses`; this list is what keeps connect's MCP wrapping and
|
|
150
|
+
* tamper restore, which cover every installed harness, away from them.
|
|
151
|
+
* `intutic init` clears it.
|
|
152
|
+
*/
|
|
153
|
+
disconnectedHarnesses?: HarnessType[];
|
|
147
154
|
}
|
|
148
155
|
/** Local integrity store at .intutic/integrity.json (per-workspace). */
|
|
149
156
|
export interface IntegrityStore {
|
|
@@ -154,14 +161,23 @@ export interface IntegrityStore {
|
|
|
154
161
|
/** Canonical hashes of synced files. */
|
|
155
162
|
files: Record<string, string>;
|
|
156
163
|
}
|
|
157
|
-
/**
|
|
164
|
+
/**
|
|
165
|
+
* A single harness config file captured by the daemon.
|
|
166
|
+
*
|
|
167
|
+
* `content` is present only when the workspace's `configBodyUpload` is on;
|
|
168
|
+
* without it the capture is metadata only. The hash is of the text after
|
|
169
|
+
* secret redaction, the text that is (or would be) uploaded, so the chain
|
|
170
|
+
* does not move when the setting is turned on or off.
|
|
171
|
+
*/
|
|
158
172
|
export interface CapturedConfigFile {
|
|
159
173
|
/** Relative file path (e.g., `.cursorrules`, `CLAUDE.md`). */
|
|
160
174
|
path: string;
|
|
161
|
-
/**
|
|
162
|
-
content
|
|
163
|
-
/** SHA-256
|
|
175
|
+
/** File content with credential-shaped strings redacted, when uploaded. */
|
|
176
|
+
content?: string;
|
|
177
|
+
/** SHA-256 hex of the redacted content. */
|
|
164
178
|
contentHash: string;
|
|
179
|
+
/** Size of the file on disk, in bytes. */
|
|
180
|
+
sizeBytes: number;
|
|
165
181
|
}
|
|
166
182
|
/** Payload sent by daemon to capture harness config snapshots (multi-file). */
|
|
167
183
|
export interface BatchConfigCapturePayload {
|
|
@@ -172,7 +188,13 @@ export interface BatchConfigCapturePayload {
|
|
|
172
188
|
/** Captured config files. */
|
|
173
189
|
files: CapturedConfigFile[];
|
|
174
190
|
}
|
|
175
|
-
/**
|
|
191
|
+
/**
|
|
192
|
+
* Structured diff between a config snapshot and its predecessor.
|
|
193
|
+
*
|
|
194
|
+
* `contentUploaded` is false when either snapshot was captured without its
|
|
195
|
+
* content (`configBodyUpload` off): the history knows the file changed, not
|
|
196
|
+
* how, so the counts are zero and both contents null.
|
|
197
|
+
*/
|
|
176
198
|
export interface ConfigDiff {
|
|
177
199
|
/** Lines added. */
|
|
178
200
|
addedLines: number;
|
|
@@ -180,10 +202,12 @@ export interface ConfigDiff {
|
|
|
180
202
|
removedLines: number;
|
|
181
203
|
/** Summary of changes. */
|
|
182
204
|
summary: string;
|
|
183
|
-
/** Previous content (null
|
|
205
|
+
/** Previous content (null for the first snapshot, or when not uploaded). */
|
|
184
206
|
previousContent: string | null;
|
|
185
|
-
/** Current content. */
|
|
186
|
-
currentContent: string;
|
|
207
|
+
/** Current content (null when not uploaded). */
|
|
208
|
+
currentContent: string | null;
|
|
209
|
+
/** Whether both snapshots carry content, so the diff is a real one. */
|
|
210
|
+
contentUploaded: boolean;
|
|
187
211
|
}
|
|
188
212
|
/** Zod schema for SOP hash report (daemon → control plane). */
|
|
189
213
|
export declare const SopHashReportSchema: z.ZodObject<{
|
|
@@ -223,6 +247,7 @@ export declare const SopHashReportSchema: z.ZodObject<{
|
|
|
223
247
|
readonly PYDANTIC_AI: "pydantic-ai";
|
|
224
248
|
readonly SMOLAGENTS: "smolagents";
|
|
225
249
|
readonly STRANDS: "strands";
|
|
250
|
+
readonly AGENT_FRAMEWORK: "agent-framework";
|
|
226
251
|
readonly MASTRA: "mastra";
|
|
227
252
|
readonly VERCEL_AI_SDK: "vercel-ai-sdk";
|
|
228
253
|
readonly EVE: "eve";
|
|
@@ -251,7 +276,7 @@ export declare const SopHashReportSchema: z.ZodObject<{
|
|
|
251
276
|
reportedAt: z.ZodString;
|
|
252
277
|
}, "strip", z.ZodTypeAny, {
|
|
253
278
|
workspaceId: string;
|
|
254
|
-
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
279
|
+
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
255
280
|
files: {
|
|
256
281
|
filePath: string;
|
|
257
282
|
localHash: string;
|
|
@@ -261,7 +286,7 @@ export declare const SopHashReportSchema: z.ZodObject<{
|
|
|
261
286
|
reportedAt: string;
|
|
262
287
|
}, {
|
|
263
288
|
workspaceId: string;
|
|
264
|
-
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
289
|
+
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
265
290
|
files: {
|
|
266
291
|
filePath: string;
|
|
267
292
|
localHash: string;
|
|
@@ -312,6 +337,7 @@ export declare const DaemonStatusSchema: z.ZodObject<{
|
|
|
312
337
|
readonly PYDANTIC_AI: "pydantic-ai";
|
|
313
338
|
readonly SMOLAGENTS: "smolagents";
|
|
314
339
|
readonly STRANDS: "strands";
|
|
340
|
+
readonly AGENT_FRAMEWORK: "agent-framework";
|
|
315
341
|
readonly MASTRA: "mastra";
|
|
316
342
|
readonly VERCEL_AI_SDK: "vercel-ai-sdk";
|
|
317
343
|
readonly EVE: "eve";
|
|
@@ -325,12 +351,12 @@ export declare const DaemonStatusSchema: z.ZodObject<{
|
|
|
325
351
|
detected: z.ZodBoolean;
|
|
326
352
|
lastWriteAt: z.ZodNullable<z.ZodString>;
|
|
327
353
|
}, "strip", z.ZodTypeAny, {
|
|
328
|
-
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
354
|
+
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
329
355
|
configPath: string;
|
|
330
356
|
detected: boolean;
|
|
331
357
|
lastWriteAt: string | null;
|
|
332
358
|
}, {
|
|
333
|
-
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
359
|
+
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
334
360
|
configPath: string;
|
|
335
361
|
detected: boolean;
|
|
336
362
|
lastWriteAt: string | null;
|
|
@@ -355,7 +381,7 @@ export declare const DaemonStatusSchema: z.ZodObject<{
|
|
|
355
381
|
connectedSince: string;
|
|
356
382
|
lastSyncAt: string;
|
|
357
383
|
harnesses: {
|
|
358
|
-
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
384
|
+
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
359
385
|
configPath: string;
|
|
360
386
|
detected: boolean;
|
|
361
387
|
lastWriteAt: string | null;
|
|
@@ -372,7 +398,7 @@ export declare const DaemonStatusSchema: z.ZodObject<{
|
|
|
372
398
|
connectedSince: string;
|
|
373
399
|
lastSyncAt: string;
|
|
374
400
|
harnesses: {
|
|
375
|
-
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
401
|
+
type: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
376
402
|
configPath: string;
|
|
377
403
|
detected: boolean;
|
|
378
404
|
lastWriteAt: string | null;
|
|
@@ -422,6 +448,7 @@ export declare const BatchConfigCapturePayloadSchema: z.ZodObject<{
|
|
|
422
448
|
readonly PYDANTIC_AI: "pydantic-ai";
|
|
423
449
|
readonly SMOLAGENTS: "smolagents";
|
|
424
450
|
readonly STRANDS: "strands";
|
|
451
|
+
readonly AGENT_FRAMEWORK: "agent-framework";
|
|
425
452
|
readonly MASTRA: "mastra";
|
|
426
453
|
readonly VERCEL_AI_SDK: "vercel-ai-sdk";
|
|
427
454
|
readonly EVE: "eve";
|
|
@@ -433,32 +460,37 @@ export declare const BatchConfigCapturePayloadSchema: z.ZodObject<{
|
|
|
433
460
|
}>;
|
|
434
461
|
files: z.ZodArray<z.ZodObject<{
|
|
435
462
|
path: z.ZodString;
|
|
436
|
-
content: z.ZodString
|
|
463
|
+
content: z.ZodOptional<z.ZodString>;
|
|
437
464
|
contentHash: z.ZodString;
|
|
465
|
+
sizeBytes: z.ZodNumber;
|
|
438
466
|
}, "strip", z.ZodTypeAny, {
|
|
439
467
|
path: string;
|
|
440
|
-
content: string;
|
|
441
468
|
contentHash: string;
|
|
469
|
+
sizeBytes: number;
|
|
470
|
+
content?: string | undefined;
|
|
442
471
|
}, {
|
|
443
472
|
path: string;
|
|
444
|
-
content: string;
|
|
445
473
|
contentHash: string;
|
|
474
|
+
sizeBytes: number;
|
|
475
|
+
content?: string | undefined;
|
|
446
476
|
}>, "many">;
|
|
447
477
|
}, "strip", z.ZodTypeAny, {
|
|
448
478
|
workspaceId: string;
|
|
449
|
-
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
479
|
+
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
450
480
|
files: {
|
|
451
481
|
path: string;
|
|
452
|
-
content: string;
|
|
453
482
|
contentHash: string;
|
|
483
|
+
sizeBytes: number;
|
|
484
|
+
content?: string | undefined;
|
|
454
485
|
}[];
|
|
455
486
|
}, {
|
|
456
487
|
workspaceId: string;
|
|
457
|
-
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
488
|
+
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi" | "cline" | "roo-code" | "continue" | "claude-desktop" | "goose" | "open-webui" | "github-copilot" | "langgraph" | "muse-code" | "grok" | "opencode" | "dsh" | "xirp" | "agentic-orchestrator" | "langchain" | "crewai" | "autogen" | "ag2" | "google-adk" | "openai-agents" | "pydantic-ai" | "smolagents" | "strands" | "agent-framework" | "mastra" | "vercel-ai-sdk" | "eve" | "trueforge" | "ai-sdk-harness" | "ai-sdk-workflow" | "agentcore-runtime" | "trueforge-server";
|
|
458
489
|
files: {
|
|
459
490
|
path: string;
|
|
460
|
-
content: string;
|
|
461
491
|
contentHash: string;
|
|
492
|
+
sizeBytes: number;
|
|
493
|
+
content?: string | undefined;
|
|
462
494
|
}[];
|
|
463
495
|
}>;
|
|
464
496
|
//# sourceMappingURL=sync.d.ts.map
|
package/dist/sync.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sync.d.ts","sourceRoot":"","sources":["../src/sync.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AACxC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAA;AAG/D,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAK7C,oDAAoD;AACpD,MAAM,WAAW,YAAY;IAC3B,uBAAuB;IACvB,KAAK,EAAE,MAAM,CAAA;IACb,gCAAgC;IAChC,KAAK,EAAE,MAAM,CAAA;IACb,oEAAoE;IACpE,OAAO,EAAE,MAAM,CAAA;IACf,gDAAgD;IAChD,WAAW,EAAE,MAAM,CAAA;IACnB,0DAA0D;IAC1D,cAAc,EAAE,WAAW,EAAE,CAAA;IAC7B,6FAA6F;IAC7F,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;AAED,6DAA6D;AAC7D,MAAM,WAAW,iBAAiB;IAChC,wCAAwC;IACxC,WAAW,EAAE,MAAM,CAAA;IACnB,yEAAyE;IACzE,aAAa,EAAE,MAAM,CAAA;IACrB,oDAAoD;IACpD,IAAI,EAAE,YAAY,EAAE,CAAA;IACpB,sEAAsE;IACtE,Q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AAE,OAAO,CAAA;CACzB;AAID,+DAA+D;AAC/D,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAU9B,CAAA;AAEF,gDAAgD;AAChD,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiB7B,CAAA;AAEF,4EAA4E;AAC5E,eAAO,MAAM,+BAA+B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAS1C,CAAA"}
|
package/dist/sync.js
CHANGED
|
@@ -49,8 +49,9 @@ exports.BatchConfigCapturePayloadSchema = zod_1.z.object({
|
|
|
49
49
|
harnessType: zod_1.z.nativeEnum(enums_js_1.HarnessType),
|
|
50
50
|
files: zod_1.z.array(zod_1.z.object({
|
|
51
51
|
path: zod_1.z.string().min(1),
|
|
52
|
-
content: zod_1.z.string(),
|
|
53
|
-
contentHash: zod_1.z.string().
|
|
52
|
+
content: zod_1.z.string().optional(),
|
|
53
|
+
contentHash: zod_1.z.string().regex(/^[0-9a-f]{64}$/),
|
|
54
|
+
sizeBytes: zod_1.z.number().int().nonnegative(),
|
|
54
55
|
})),
|
|
55
56
|
});
|
|
56
57
|
//# sourceMappingURL=sync.js.map
|
package/dist/sync.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sync.js","sourceRoot":"","sources":["../src/sync.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;;AAEH,6BAAuB;AACvB,yCAAwC;
|
|
1
|
+
{"version":3,"file":"sync.js","sourceRoot":"","sources":["../src/sync.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;;A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ode, BypassEnforcementTier } from './enums.js';
|
|
14
|
+
import type { SsoGroupPolicy } from './attenuation.js';
|
|
14
15
|
export type { McpProxyFailBehavior, McpProxyMode, BypassEnforcementTier };
|
|
16
|
+
/**
|
|
17
|
+
* The MCP governance proxy's anomaly detectors, by id. The proxy's own
|
|
18
|
+
* `DETECTOR_BASE_DISPOSITION` (packages/mcp-proxy/src/anomaly/index.ts) is
|
|
19
|
+
* typed against this list, so a detector added there without being added
|
|
20
|
+
* here fails to compile, and `mcpAnomalyOverrides` cannot name one that does
|
|
21
|
+
* not exist.
|
|
22
|
+
*/
|
|
23
|
+
export declare const MCP_ANOMALY_DETECTOR_IDS: readonly ["consecutive_repeat", "ping_pong_cycle", "landmark_cycle", "tool_diversity_collapse", "code_as_action", "tool_poisoning", "dlp_escalation"];
|
|
24
|
+
export type McpAnomalyDetectorId = (typeof MCP_ANOMALY_DETECTOR_IDS)[number];
|
|
15
25
|
/**
|
|
16
26
|
* Per-workspace MCP governance settings.
|
|
17
27
|
*
|
|
@@ -63,6 +73,15 @@ export interface WorkspaceSettings {
|
|
|
63
73
|
* recorded SSO login yet. Cleared when the gate is turned off.
|
|
64
74
|
*/
|
|
65
75
|
ssoKeyGateEnabledAt: string | null;
|
|
76
|
+
/**
|
|
77
|
+
* Tools only members of named identity-provider groups may run, and tools
|
|
78
|
+
* only an on-behalf-of token may call (`SsoGroupPolicySchema`). Absent: no
|
|
79
|
+
* group restriction; `null` in a settings write clears it, and is never
|
|
80
|
+
* stored. Snake-case because the gates and the policy responses have always
|
|
81
|
+
* read it under this key. Every gate decides with `evaluateSsoGroupClearance`;
|
|
82
|
+
* see `ssoGroupClearance.ts`.
|
|
83
|
+
*/
|
|
84
|
+
sso_group_policy?: SsoGroupPolicy | null;
|
|
66
85
|
/**
|
|
67
86
|
* Bring-your-own-cloud trace storage. Optional — absent means Intutic-managed
|
|
68
87
|
* storage. Previously accessed only through `as unknown as` casts; typed here
|
|
@@ -291,6 +310,39 @@ export interface WorkspaceSettings {
|
|
|
291
310
|
* start refusing every MCP server because a default changed.
|
|
292
311
|
*/
|
|
293
312
|
mcpAllowedServers?: string[];
|
|
313
|
+
/**
|
|
314
|
+
* What the MCP governance proxy does with a server the workspace has not
|
|
315
|
+
* approved in its MCP server registry. `allow` (the default, and what an
|
|
316
|
+
* absent value means) lets every server through that is not explicitly
|
|
317
|
+
* blocked; `deny` refuses every server until an OWNER or ADMIN approves it,
|
|
318
|
+
* and a server the proxy has not seen before lands in the registry as a
|
|
319
|
+
* candidate awaiting that decision. A blocked server is refused under both.
|
|
320
|
+
* Delivered to the proxy with the registry decisions (`mcpRegistry` on
|
|
321
|
+
* `GET /api/v1/sop/rules` and `GET /api/v1/policy/resolve`).
|
|
322
|
+
*/
|
|
323
|
+
mcpDefaultPolicy?: 'allow' | 'deny';
|
|
324
|
+
/**
|
|
325
|
+
* What the MCP governance proxy does when a prompt-injection pattern
|
|
326
|
+
* matches: `warn` reports it and lets the call (or result) through, `block`
|
|
327
|
+
* refuses the call or withholds the result. Delivered with the MCP policy
|
|
328
|
+
* and wins over the proxy's local `INTUTIC_MCP_INJECTION_ACTION`; absent
|
|
329
|
+
* leaves the local setting (default `warn`) in force.
|
|
330
|
+
*/
|
|
331
|
+
mcpInjectionAction?: 'warn' | 'block';
|
|
332
|
+
/**
|
|
333
|
+
* The MCP proxy's anomaly detectors: `enforce` lets each act up to its own
|
|
334
|
+
* ceiling, `warn` reports without blocking, `off` skips them. Delivered with
|
|
335
|
+
* the MCP policy and wins over `INTUTIC_MCP_ANOMALY_MODE`; absent leaves the
|
|
336
|
+
* local setting (default `enforce`) in force.
|
|
337
|
+
*/
|
|
338
|
+
mcpAnomalyMode?: 'enforce' | 'warn' | 'off';
|
|
339
|
+
/**
|
|
340
|
+
* Per-detector overrides for the MCP proxy's anomaly detectors, by
|
|
341
|
+
* detector id. A value can only demote a detector below its own ceiling,
|
|
342
|
+
* never promote it. Merged per detector over `INTUTIC_MCP_ANOMALY_OVERRIDES`,
|
|
343
|
+
* this setting winning.
|
|
344
|
+
*/
|
|
345
|
+
mcpAnomalyOverrides?: Partial<Record<McpAnomalyDetectorId, 'steer' | 'reask' | 'kill' | 'off'>>;
|
|
294
346
|
/**
|
|
295
347
|
* Workspace-supplied prompt-injection regex sources for the MCP governance
|
|
296
348
|
* proxy (TD-436), on top of its hardcoded floor. Delivered with the rest of
|
|
@@ -450,30 +502,6 @@ export interface WorkspaceSettings {
|
|
|
450
502
|
* statement.
|
|
451
503
|
*/
|
|
452
504
|
semanticSkillAnalysisEnabled?: boolean;
|
|
453
|
-
/**
|
|
454
|
-
* BYO judge model for the MANAGED LLM-as-judge path (LLD #70).
|
|
455
|
-
*
|
|
456
|
-
* When set, chunk/finalize judge calls for this workspace run on this
|
|
457
|
-
* model, routed through the platform data-plane gateway with the
|
|
458
|
-
* workspace's own vk_ — so the completion is billed to the workspace's
|
|
459
|
-
* provider key (the key wizard), not the platform. Trade-offs, stated
|
|
460
|
-
* plainly rather than implied:
|
|
461
|
-
* - This REPLACES the platform's independent trusted monitor
|
|
462
|
-
* (`INTUTIC_TRUSTED_MONITOR_MODEL`) for this workspace. Verdicts are
|
|
463
|
-
* stamped `[workspace-judge]`; a judge equal to the monitored model is
|
|
464
|
-
* additionally stamped `[self-graded]` — provenance stays visible, it
|
|
465
|
-
* is never re-labelled as independent.
|
|
466
|
-
* - Judged content still transits the control plane and the platform
|
|
467
|
-
* gateway to the workspace's provider. The self-hosted local judge
|
|
468
|
-
* (`INTUTIC_GATEWAY_LOCAL_JUDGE`) remains the keep-content-in-org path.
|
|
469
|
-
* - Chunk judging fires per paragraph — that cost lands on the
|
|
470
|
-
* workspace's provider key.
|
|
471
|
-
* - A workspace policy KILL (DLP, budget) on the judge call itself fails
|
|
472
|
-
* safe to the standard judge-unavailable note, not a bypass.
|
|
473
|
-
*
|
|
474
|
-
* `null`/absent = the platform trusted monitor, exactly as before.
|
|
475
|
-
*/
|
|
476
|
-
managedJudgeModel?: string | null;
|
|
477
505
|
/**
|
|
478
506
|
* Opt-in VirusTotal hash lookup for skill-bundled SCRIPTS (Phase S4,
|
|
479
507
|
* TD-361). When true, and only when a `connector_credentials` row for
|
|
@@ -491,6 +519,22 @@ export interface WorkspaceSettings {
|
|
|
491
519
|
* that separate decision, which this setting does not reverse.
|
|
492
520
|
*/
|
|
493
521
|
virusTotalSkillLookupEnabled?: boolean;
|
|
522
|
+
/**
|
|
523
|
+
* Upload the content of harness config files, not only their hashes.
|
|
524
|
+
*
|
|
525
|
+
* `intutic connect` captures each recorded harness's rules file (the list is
|
|
526
|
+
* `HARNESS_FILES` in `@intutic/sync-daemon`). Off, it uploads the file's
|
|
527
|
+
* path, the SHA-256 of its redacted text, its size, the harness and the
|
|
528
|
+
* time: the config history records what changed and when, and its hash
|
|
529
|
+
* chain stays verifiable. On, it also uploads the text, with credential-
|
|
530
|
+
* shaped strings replaced by `[redacted]` before it leaves the machine,
|
|
531
|
+
* which is what config diffs and SkillOpt's config-edit suggestions need.
|
|
532
|
+
*
|
|
533
|
+
* Off by default: file content leaving developer machines is a privacy
|
|
534
|
+
* choice a workspace makes, not one a default makes for it. The control
|
|
535
|
+
* plane refuses a body sent while this is off.
|
|
536
|
+
*/
|
|
537
|
+
configBodyUpload?: boolean;
|
|
494
538
|
/**
|
|
495
539
|
* Fraction of ingested traces that receive the two heavier, LLM-adjacent
|
|
496
540
|
* security probes — `traceIngestClassifier.classifyTraceAtIngest`'s
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workspaceSettings.d.ts","sourceRoot":"","sources":["../src/workspaceSettings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,oBAAoB,EAAE,YAAY,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"workspaceSettings.d.ts","sourceRoot":"","sources":["../src/workspaceSettings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EA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E;QACzE,UAAU,CAAC,EAAE,MAAM,EAAE,CAAA;KACtB,CAAA;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,uBAAuB,CAAC,EAAE,QAAQ,GAAG,SAAS,GAAG,KAAK,CAAA;IAEtD;;;;;;;;;;OAUG;IACH,eAAe,CAAC,EAAE,MAAM,EAAE,CAAA;IAE1B;;;;;;OAMG;IACH,2BAA2B,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAEpD;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,mBAAmB,CAAC,EAAE,OAAO,CAAA;IAE7B;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,4BAA4B,CAAC,EAAE,OAAO,CAAA;IAEtC;;;;;;;;;;;;;;;OAeG;IACH,4BAA4B,CAAC,EAAE,OAAO,CAAA;IAEtC;;;;;;;;;;;;;;OAcG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAE1B;;;;;;;;;;;;;;;;OAgBG;IACH,uBAAuB,CAAC,EAAE,MAAM,CAAA;IAEhC;;;;;;;;;;;;;;;;;;OAkBG;IACH,6BAA6B,EAAE,OAAO,CAAA;CACvC;AAED;;;;GAIG;AACH,eAAO,MAAM,0BAA0B,EAAE,iBAqFxC,CAAA;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CACtC,MAAM,EAAE,OAAO,CAAC,iBAAiB,CAAC,GAAG,IAAI,GAAG,SAAS,GACpD,iBAAiB,CAKnB;AAED;;;;;;;;GAQG;AACH,wBAAgB,8BAA8B,CAAC,QAAQ,EAAE,iBAAiB,GAAG,MAAM,CAIlF"}
|
|
@@ -12,9 +12,25 @@
|
|
|
12
12
|
* @module
|
|
13
13
|
*/
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.DEFAULT_WORKSPACE_SETTINGS = void 0;
|
|
15
|
+
exports.DEFAULT_WORKSPACE_SETTINGS = exports.MCP_ANOMALY_DETECTOR_IDS = void 0;
|
|
16
16
|
exports.resolveWorkspaceSettings = resolveWorkspaceSettings;
|
|
17
17
|
exports.resolveSecurityProbeSampleRate = resolveSecurityProbeSampleRate;
|
|
18
|
+
/**
|
|
19
|
+
* The MCP governance proxy's anomaly detectors, by id. The proxy's own
|
|
20
|
+
* `DETECTOR_BASE_DISPOSITION` (packages/mcp-proxy/src/anomaly/index.ts) is
|
|
21
|
+
* typed against this list, so a detector added there without being added
|
|
22
|
+
* here fails to compile, and `mcpAnomalyOverrides` cannot name one that does
|
|
23
|
+
* not exist.
|
|
24
|
+
*/
|
|
25
|
+
exports.MCP_ANOMALY_DETECTOR_IDS = [
|
|
26
|
+
'consecutive_repeat',
|
|
27
|
+
'ping_pong_cycle',
|
|
28
|
+
'landmark_cycle',
|
|
29
|
+
'tool_diversity_collapse',
|
|
30
|
+
'code_as_action',
|
|
31
|
+
'tool_poisoning',
|
|
32
|
+
'dlp_escalation',
|
|
33
|
+
];
|
|
18
34
|
/**
|
|
19
35
|
* Default workspace settings.
|
|
20
36
|
* Applied when a workspace has no explicit settings (new workspaces)
|
|
@@ -75,9 +91,6 @@ exports.DEFAULT_WORKSPACE_SETTINGS = {
|
|
|
75
91
|
// Only load-bearing once reviewHoldBypassEnabled is true; the value here is
|
|
76
92
|
// what "enabled but unset" resolves to.
|
|
77
93
|
reviewHoldBypassTtlMinutes: 10,
|
|
78
|
-
// Platform trusted monitor judges by default — see the field doc for what
|
|
79
|
-
// setting a workspace's own model trades away.
|
|
80
|
-
managedJudgeModel: null,
|
|
81
94
|
// Off by default — see the field doc for why a growing auto-written
|
|
82
95
|
// context file must be opt-in.
|
|
83
96
|
decisionsLogEnabled: false,
|
|
@@ -100,6 +113,8 @@ exports.DEFAULT_WORKSPACE_SETTINGS = {
|
|
|
100
113
|
// Off by default — see the field doc for the hash-only doctrine and why
|
|
101
114
|
// this must never turn on for a workspace that never configured it.
|
|
102
115
|
virusTotalSkillLookupEnabled: false,
|
|
116
|
+
// Off by default — see the field doc: hashes and metadata only.
|
|
117
|
+
configBodyUpload: false,
|
|
103
118
|
// ON by default — see the field doc. Opting out stops label retention for
|
|
104
119
|
// the judge fine-tuning dataset, never card delivery itself.
|
|
105
120
|
governanceCardLabelingEnabled: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workspaceSettings.js","sourceRoot":"","sources":["../src/workspaceSettings.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;GAWG;;;
|
|
1
|
+
{"version":3,"file":"workspaceSettings.js","sourceRoot":"","sources":["../src/workspaceSettings.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;GAWG;;;AAosBH,4DAOC;AAWD,wEAIC;AAltBD;;;;;;GAMG;AACU,QAAA,wBAAwB,GAAG;IACtC,oBAAoB;IACpB,iBAAiB;IACjB,gBAAgB;IAChB,yBAAyB;IACzB,gBAAgB;IAChB,gBAAgB;IAChB,gBAAgB;CACR,CAAA;AA6kBV;;;;GAIG;AACU,QAAA,0BAA0B,GAAsB;IAC3D,oBAAoB,EAAE,MAAM;IAC5B,sBAAsB,EAAE,IAAI;IAC5B,iFAAiF;IACjF,iFAAiF;IACjF,+EAA+E;IAC/E,kFAAkF;IAClF,iFAAiF;IACjF,0EAA0E;IAC1E,iBAAiB,EAAE,EAAE;IACrB,mBAAmB,EAAE,IAAI;IACzB,YAAY,EAAU,aAAa;IACnC,qBAAqB,EAAE,SAAS;IAChC,YAAY,EAAE;QACZ,iBAAiB,EAAE,KAAK;QACxB,uBAAuB,EAAE,KAAK;QAC9B,0BAA0B,EAAE,KAAK;QACjC,qBAAqB,EAAE,KAAK;QAC5B,2EAA2E;QAC3E,uEAAuE;QACvE,qBAAqB,EAAE,KAAK;QAC5B,sBAAsB,EAAE,KAAK;QAC7B,sBAAsB,EAAE,KAAK;QAC7B,oEAAoE;QACpE,yCAAyC;QACzC,wBAAwB,EAAE,KAAK;KAChC;IACD,2BAA2B,EAAE,KAAK;IAClC,wEAAwE;IACxE,qEAAqE;IACrE,w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