@blink-authority-com/claude-code-plugin 1.0.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/LICENSE +21 -0
- package/README.md +146 -0
- package/dist/bsec-client.d.ts +35 -0
- package/dist/bsec-client.d.ts.map +1 -0
- package/dist/bsec-client.js +122 -0
- package/dist/bsec-client.js.map +1 -0
- package/dist/docs/cache.d.ts +19 -0
- package/dist/docs/cache.d.ts.map +1 -0
- package/dist/docs/cache.js +92 -0
- package/dist/docs/cache.js.map +1 -0
- package/dist/docs/fetcher.d.ts +19 -0
- package/dist/docs/fetcher.d.ts.map +1 -0
- package/dist/docs/fetcher.js +81 -0
- package/dist/docs/fetcher.js.map +1 -0
- package/dist/docs/parser.d.ts +33 -0
- package/dist/docs/parser.d.ts.map +1 -0
- package/dist/docs/parser.js +145 -0
- package/dist/docs/parser.js.map +1 -0
- package/dist/docs/search.d.ts +38 -0
- package/dist/docs/search.d.ts.map +1 -0
- package/dist/docs/search.js +180 -0
- package/dist/docs/search.js.map +1 -0
- package/dist/docs/tools/api.d.ts +12 -0
- package/dist/docs/tools/api.d.ts.map +1 -0
- package/dist/docs/tools/api.js +58 -0
- package/dist/docs/tools/api.js.map +1 -0
- package/dist/docs/tools/cli.d.ts +12 -0
- package/dist/docs/tools/cli.d.ts.map +1 -0
- package/dist/docs/tools/cli.js +56 -0
- package/dist/docs/tools/cli.js.map +1 -0
- package/dist/docs/tools/concepts.d.ts +18 -0
- package/dist/docs/tools/concepts.d.ts.map +1 -0
- package/dist/docs/tools/concepts.js +136 -0
- package/dist/docs/tools/concepts.js.map +1 -0
- package/dist/docs/tools/sdk.d.ts +12 -0
- package/dist/docs/tools/sdk.d.ts.map +1 -0
- package/dist/docs/tools/sdk.js +72 -0
- package/dist/docs/tools/sdk.js.map +1 -0
- package/dist/docs/tools/search.d.ts +11 -0
- package/dist/docs/tools/search.d.ts.map +1 -0
- package/dist/docs/tools/search.js +36 -0
- package/dist/docs/tools/search.js.map +1 -0
- package/dist/docs/types.d.ts +70 -0
- package/dist/docs/types.d.ts.map +1 -0
- package/dist/docs/types.js +8 -0
- package/dist/docs/types.js.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +622 -0
- package/dist/index.js.map +1 -0
- package/dist/prompts/debug.d.ts +16 -0
- package/dist/prompts/debug.d.ts.map +1 -0
- package/dist/prompts/debug.js +34 -0
- package/dist/prompts/debug.js.map +1 -0
- package/dist/prompts/integrate.d.ts +16 -0
- package/dist/prompts/integrate.d.ts.map +1 -0
- package/dist/prompts/integrate.js +30 -0
- package/dist/prompts/integrate.js.map +1 -0
- package/dist/prompts/review.d.ts +16 -0
- package/dist/prompts/review.d.ts.map +1 -0
- package/dist/prompts/review.js +28 -0
- package/dist/prompts/review.js.map +1 -0
- package/dist/resources/changelog.d.ts +22 -0
- package/dist/resources/changelog.d.ts.map +1 -0
- package/dist/resources/changelog.js +55 -0
- package/dist/resources/changelog.js.map +1 -0
- package/dist/resources/errors.d.ts +16 -0
- package/dist/resources/errors.d.ts.map +1 -0
- package/dist/resources/errors.js +103 -0
- package/dist/resources/errors.js.map +1 -0
- package/dist/resources/patterns.d.ts +16 -0
- package/dist/resources/patterns.d.ts.map +1 -0
- package/dist/resources/patterns.js +151 -0
- package/dist/resources/patterns.js.map +1 -0
- package/dist/templates/approval-workflow.d.ts +6 -0
- package/dist/templates/approval-workflow.d.ts.map +1 -0
- package/dist/templates/approval-workflow.js +467 -0
- package/dist/templates/approval-workflow.js.map +1 -0
- package/dist/templates/audit-trail.d.ts +6 -0
- package/dist/templates/audit-trail.d.ts.map +1 -0
- package/dist/templates/audit-trail.js +396 -0
- package/dist/templates/audit-trail.js.map +1 -0
- package/dist/templates/cli-tool.d.ts +6 -0
- package/dist/templates/cli-tool.d.ts.map +1 -0
- package/dist/templates/cli-tool.js +346 -0
- package/dist/templates/cli-tool.js.map +1 -0
- package/dist/templates/express-api.d.ts +6 -0
- package/dist/templates/express-api.d.ts.map +1 -0
- package/dist/templates/express-api.js +314 -0
- package/dist/templates/express-api.js.map +1 -0
- package/dist/templates/notary.d.ts +6 -0
- package/dist/templates/notary.d.ts.map +1 -0
- package/dist/templates/notary.js +360 -0
- package/dist/templates/notary.js.map +1 -0
- package/dist/test.d.ts +8 -0
- package/dist/test.d.ts.map +1 -0
- package/dist/test.js +140 -0
- package/dist/test.js.map +1 -0
- package/dist/tools/add-signing.d.ts +19 -0
- package/dist/tools/add-signing.d.ts.map +1 -0
- package/dist/tools/add-signing.js +317 -0
- package/dist/tools/add-signing.js.map +1 -0
- package/dist/tools/decode.d.ts +13 -0
- package/dist/tools/decode.d.ts.map +1 -0
- package/dist/tools/decode.js +262 -0
- package/dist/tools/decode.js.map +1 -0
- package/dist/tools/hierarchy.d.ts +13 -0
- package/dist/tools/hierarchy.d.ts.map +1 -0
- package/dist/tools/hierarchy.js +319 -0
- package/dist/tools/hierarchy.js.map +1 -0
- package/dist/tools/lint.d.ts +13 -0
- package/dist/tools/lint.d.ts.map +1 -0
- package/dist/tools/lint.js +323 -0
- package/dist/tools/lint.js.map +1 -0
- package/dist/tools/scaffold.d.ts +11 -0
- package/dist/tools/scaffold.d.ts.map +1 -0
- package/dist/tools/scaffold.js +84 -0
- package/dist/tools/scaffold.js.map +1 -0
- package/dist/tools/sign-test.d.ts +17 -0
- package/dist/tools/sign-test.d.ts.map +1 -0
- package/dist/tools/sign-test.js +126 -0
- package/dist/tools/sign-test.js.map +1 -0
- package/dist/tools/test-vectors.d.ts +13 -0
- package/dist/tools/test-vectors.d.ts.map +1 -0
- package/dist/tools/test-vectors.js +169 -0
- package/dist/tools/test-vectors.js.map +1 -0
- package/dist/tools/verify-local.d.ts +17 -0
- package/dist/tools/verify-local.d.ts.map +1 -0
- package/dist/tools/verify-local.js +233 -0
- package/dist/tools/verify-local.js.map +1 -0
- package/dist/tools/verify-test.d.ts +17 -0
- package/dist/tools/verify-test.d.ts.map +1 -0
- package/dist/tools/verify-test.js +107 -0
- package/dist/tools/verify-test.js.map +1 -0
- package/package.json +54 -0
|
@@ -0,0 +1,319 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* blink_hierarchy_design tool handler.
|
|
3
|
+
*
|
|
4
|
+
* Given an organisational description, suggests a BLINK key hierarchy
|
|
5
|
+
* with INS naming, algorithm recommendations, and delegation model.
|
|
6
|
+
*/
|
|
7
|
+
// ---------------------------------------------------------------------------
|
|
8
|
+
// Keyword patterns
|
|
9
|
+
// ---------------------------------------------------------------------------
|
|
10
|
+
const DEPT_KEYWORDS = {
|
|
11
|
+
treasury: { type: 'dept', subtype: 'treasury' },
|
|
12
|
+
finance: { type: 'dept', subtype: 'finance' },
|
|
13
|
+
trading: { type: 'dept', subtype: 'trading' },
|
|
14
|
+
engineering: { type: 'dept', subtype: 'engineering' },
|
|
15
|
+
compliance: { type: 'dept', subtype: 'compliance' },
|
|
16
|
+
legal: { type: 'dept', subtype: 'legal' },
|
|
17
|
+
operations: { type: 'dept', subtype: 'operations' },
|
|
18
|
+
security: { type: 'dept', subtype: 'security' },
|
|
19
|
+
hr: { type: 'dept', subtype: 'hr' },
|
|
20
|
+
marketing: { type: 'dept', subtype: 'marketing' },
|
|
21
|
+
sales: { type: 'dept', subtype: 'sales' },
|
|
22
|
+
research: { type: 'dept', subtype: 'research' },
|
|
23
|
+
};
|
|
24
|
+
const SERVICE_KEYWORDS = {
|
|
25
|
+
api: 'api-service',
|
|
26
|
+
'web service': 'web-service',
|
|
27
|
+
microservice: 'microservice',
|
|
28
|
+
database: 'data-service',
|
|
29
|
+
payment: 'payment-service',
|
|
30
|
+
notification: 'notification-service',
|
|
31
|
+
authentication: 'auth-service',
|
|
32
|
+
auth: 'auth-service',
|
|
33
|
+
webhook: 'webhook-service',
|
|
34
|
+
gateway: 'api-gateway',
|
|
35
|
+
};
|
|
36
|
+
const AGENT_KEYWORDS = [
|
|
37
|
+
'agent', 'bot', 'automated', 'cron', 'scheduler', 'worker', 'daemon',
|
|
38
|
+
'pipeline', 'ci', 'cd', 'deployment',
|
|
39
|
+
];
|
|
40
|
+
const REGION_KEYWORDS = {
|
|
41
|
+
'us': 'us',
|
|
42
|
+
'eu': 'eu',
|
|
43
|
+
'europe': 'eu',
|
|
44
|
+
'asia': 'apac',
|
|
45
|
+
'apac': 'apac',
|
|
46
|
+
'uk': 'uk',
|
|
47
|
+
'australia': 'au',
|
|
48
|
+
'japan': 'jp',
|
|
49
|
+
'singapore': 'sg',
|
|
50
|
+
'north america': 'na',
|
|
51
|
+
'latin america': 'latam',
|
|
52
|
+
};
|
|
53
|
+
const IOT_KEYWORDS = ['iot', 'device', 'sensor', 'fleet', 'edge', 'embedded'];
|
|
54
|
+
// ---------------------------------------------------------------------------
|
|
55
|
+
// Helpers
|
|
56
|
+
// ---------------------------------------------------------------------------
|
|
57
|
+
function extractOrgName(description) {
|
|
58
|
+
// Look for quoted names or capitalized words at the start
|
|
59
|
+
const quotedMatch = description.match(/["']([^"']+)["']/);
|
|
60
|
+
if (quotedMatch)
|
|
61
|
+
return quotedMatch[1];
|
|
62
|
+
// Look for "X is a" or "X has" pattern
|
|
63
|
+
const isMatch = description.match(/^(\w+(?:\s+\w+)?)\s+(?:is|has|operates)/i);
|
|
64
|
+
if (isMatch)
|
|
65
|
+
return isMatch[1];
|
|
66
|
+
// First capitalized word
|
|
67
|
+
const capMatch = description.match(/\b([A-Z][a-z]+(?:\s+[A-Z][a-z]+)*)\b/);
|
|
68
|
+
if (capMatch)
|
|
69
|
+
return capMatch[1];
|
|
70
|
+
return 'Organization';
|
|
71
|
+
}
|
|
72
|
+
function findKeywords(text, keywords) {
|
|
73
|
+
const lower = text.toLowerCase();
|
|
74
|
+
return keywords.filter((kw) => lower.includes(kw.toLowerCase()));
|
|
75
|
+
}
|
|
76
|
+
function findMapKeywords(text, kwMap) {
|
|
77
|
+
const lower = text.toLowerCase();
|
|
78
|
+
const found = [];
|
|
79
|
+
for (const [kw, val] of Object.entries(kwMap)) {
|
|
80
|
+
if (lower.includes(kw.toLowerCase())) {
|
|
81
|
+
found.push({ keyword: kw, value: val });
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
return found;
|
|
85
|
+
}
|
|
86
|
+
function sanitiseIns(name) {
|
|
87
|
+
return name
|
|
88
|
+
.toLowerCase()
|
|
89
|
+
.replace(/[^a-z0-9.-]/g, '-')
|
|
90
|
+
.replace(/-+/g, '-')
|
|
91
|
+
.replace(/^-|-$/g, '');
|
|
92
|
+
}
|
|
93
|
+
// ---------------------------------------------------------------------------
|
|
94
|
+
// Handler
|
|
95
|
+
// ---------------------------------------------------------------------------
|
|
96
|
+
export function handleHierarchyDesign(args) {
|
|
97
|
+
const description = args.description;
|
|
98
|
+
const requirements = args.requirements || [];
|
|
99
|
+
if (!description || typeof description !== 'string' || description.trim() === '') {
|
|
100
|
+
return {
|
|
101
|
+
content: [{
|
|
102
|
+
type: 'text',
|
|
103
|
+
text: JSON.stringify({
|
|
104
|
+
error: 'Missing or empty "description" parameter. Describe your organisation.',
|
|
105
|
+
}),
|
|
106
|
+
}],
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
const orgName = extractOrgName(description);
|
|
110
|
+
const orgIns = sanitiseIns(orgName);
|
|
111
|
+
const hasPostQuantum = requirements.includes('post-quantum');
|
|
112
|
+
const hasAgentDelegation = requirements.includes('agent-delegation');
|
|
113
|
+
const hasGeoIsolation = requirements.includes('geographic-isolation');
|
|
114
|
+
const hasRegulatory = requirements.includes('regulatory-compliance');
|
|
115
|
+
const defaultAlgo = hasPostQuantum ? 'ML-DSA-44' : 'Ed25519';
|
|
116
|
+
const highValueAlgo = 'ML-DSA-44';
|
|
117
|
+
// Build hierarchy
|
|
118
|
+
const root = {
|
|
119
|
+
name: orgName,
|
|
120
|
+
type: 'org',
|
|
121
|
+
ins: orgIns,
|
|
122
|
+
algorithm: defaultAlgo,
|
|
123
|
+
rationale: `Root identity for ${orgName}. ${hasPostQuantum ? 'Post-quantum algorithm required.' : 'Ed25519 default for performance.'}`,
|
|
124
|
+
children: [],
|
|
125
|
+
};
|
|
126
|
+
const rationale = [];
|
|
127
|
+
const insExamples = [orgIns];
|
|
128
|
+
// Detect departments
|
|
129
|
+
const deptMatches = findMapKeywords(description, Object.fromEntries(Object.entries(DEPT_KEYWORDS).map(([k, v]) => [k, v.subtype])));
|
|
130
|
+
for (const dept of deptMatches) {
|
|
131
|
+
const deptIns = `${orgIns}.${dept.value}`;
|
|
132
|
+
insExamples.push(deptIns);
|
|
133
|
+
const isHighValue = ['treasury', 'finance', 'trading', 'compliance'].includes(dept.value);
|
|
134
|
+
const deptAlgo = isHighValue ? highValueAlgo : defaultAlgo;
|
|
135
|
+
const deptNode = {
|
|
136
|
+
name: dept.keyword.charAt(0).toUpperCase() + dept.keyword.slice(1),
|
|
137
|
+
type: 'dept',
|
|
138
|
+
ins: deptIns,
|
|
139
|
+
algorithm: deptAlgo,
|
|
140
|
+
rationale: isHighValue
|
|
141
|
+
? `High-value department — ${highValueAlgo} recommended for post-quantum protection.`
|
|
142
|
+
: `Standard department — ${defaultAlgo} provides good performance.`,
|
|
143
|
+
children: [],
|
|
144
|
+
};
|
|
145
|
+
// Add compliance-specific children
|
|
146
|
+
if (dept.value === 'compliance' && hasRegulatory) {
|
|
147
|
+
const auditNode = {
|
|
148
|
+
name: 'Audit Trail',
|
|
149
|
+
type: 'service',
|
|
150
|
+
ins: `${deptIns}.audit-trail`,
|
|
151
|
+
algorithm: highValueAlgo,
|
|
152
|
+
rationale: 'Audit trail signing requires post-quantum protection for long-term non-repudiation.',
|
|
153
|
+
children: [],
|
|
154
|
+
};
|
|
155
|
+
deptNode.children.push(auditNode);
|
|
156
|
+
insExamples.push(auditNode.ins);
|
|
157
|
+
}
|
|
158
|
+
// Add trading-specific children
|
|
159
|
+
if (dept.value === 'trading') {
|
|
160
|
+
const tradingAgent = {
|
|
161
|
+
name: 'Algo Trading Agent',
|
|
162
|
+
type: 'agent',
|
|
163
|
+
ins: `${deptIns}.algo-agent`,
|
|
164
|
+
algorithm: 'Ed25519',
|
|
165
|
+
rationale: 'Trading agents need low-latency signing — Ed25519 for speed.',
|
|
166
|
+
children: [],
|
|
167
|
+
};
|
|
168
|
+
deptNode.children.push(tradingAgent);
|
|
169
|
+
insExamples.push(tradingAgent.ins);
|
|
170
|
+
}
|
|
171
|
+
root.children.push(deptNode);
|
|
172
|
+
rationale.push(`${dept.keyword} department identified — ${isHighValue ? 'high-value, ML-DSA-44 recommended' : 'standard department'}.`);
|
|
173
|
+
}
|
|
174
|
+
// Detect services
|
|
175
|
+
const serviceMatches = findMapKeywords(description, SERVICE_KEYWORDS);
|
|
176
|
+
for (const svc of serviceMatches) {
|
|
177
|
+
const svcIns = `${orgIns}.services.${svc.value}`;
|
|
178
|
+
insExamples.push(svcIns);
|
|
179
|
+
const svcNode = {
|
|
180
|
+
name: svc.value.replace(/-/g, ' ').replace(/\b\w/g, (c) => c.toUpperCase()),
|
|
181
|
+
type: 'service',
|
|
182
|
+
ins: svcIns,
|
|
183
|
+
algorithm: defaultAlgo,
|
|
184
|
+
rationale: `Service "${svc.keyword}" — uses ${defaultAlgo} for signing API responses or documents.`,
|
|
185
|
+
children: [],
|
|
186
|
+
};
|
|
187
|
+
root.children.push(svcNode);
|
|
188
|
+
rationale.push(`Service "${svc.keyword}" identified — added under services namespace.`);
|
|
189
|
+
}
|
|
190
|
+
// Detect agents
|
|
191
|
+
const agentMatches = findKeywords(description, AGENT_KEYWORDS);
|
|
192
|
+
if (agentMatches.length > 0 || hasAgentDelegation) {
|
|
193
|
+
const agentsIns = `${orgIns}.agents`;
|
|
194
|
+
insExamples.push(agentsIns);
|
|
195
|
+
const agentsNode = {
|
|
196
|
+
name: 'Automated Agents',
|
|
197
|
+
type: 'agent',
|
|
198
|
+
ins: agentsIns,
|
|
199
|
+
algorithm: defaultAlgo,
|
|
200
|
+
rationale: hasAgentDelegation
|
|
201
|
+
? 'Agent delegation enabled — agents receive delegated signing authority with scope limits.'
|
|
202
|
+
: 'Automated agents grouped under a common namespace for access control.',
|
|
203
|
+
children: [],
|
|
204
|
+
};
|
|
205
|
+
for (const agentKw of agentMatches.slice(0, 5)) {
|
|
206
|
+
const agentIns = `${agentsIns}.${sanitiseIns(agentKw)}`;
|
|
207
|
+
insExamples.push(agentIns);
|
|
208
|
+
agentsNode.children.push({
|
|
209
|
+
name: agentKw.charAt(0).toUpperCase() + agentKw.slice(1),
|
|
210
|
+
type: 'agent',
|
|
211
|
+
ins: agentIns,
|
|
212
|
+
algorithm: defaultAlgo,
|
|
213
|
+
rationale: `Agent for ${agentKw} automation.`,
|
|
214
|
+
children: [],
|
|
215
|
+
});
|
|
216
|
+
}
|
|
217
|
+
root.children.push(agentsNode);
|
|
218
|
+
rationale.push(`Automated agents detected — ${hasAgentDelegation ? 'delegation model enabled' : 'grouped namespace added'}.`);
|
|
219
|
+
}
|
|
220
|
+
// Detect regions
|
|
221
|
+
const regionMatches = findMapKeywords(description, REGION_KEYWORDS);
|
|
222
|
+
if (regionMatches.length > 0 || hasGeoIsolation) {
|
|
223
|
+
for (const region of regionMatches) {
|
|
224
|
+
const regionIns = `${orgIns}.regions.${region.value}`;
|
|
225
|
+
insExamples.push(regionIns);
|
|
226
|
+
const regionNode = {
|
|
227
|
+
name: `Region: ${region.value.toUpperCase()}`,
|
|
228
|
+
type: 'region',
|
|
229
|
+
ins: regionIns,
|
|
230
|
+
algorithm: defaultAlgo,
|
|
231
|
+
rationale: hasGeoIsolation
|
|
232
|
+
? `Geographically isolated key for ${region.keyword} — independent BSEC instance recommended.`
|
|
233
|
+
: `Regional key for ${region.keyword} operations.`,
|
|
234
|
+
children: [],
|
|
235
|
+
};
|
|
236
|
+
root.children.push(regionNode);
|
|
237
|
+
}
|
|
238
|
+
rationale.push(`Geographic regions detected — ${hasGeoIsolation ? 'isolation model applied' : 'regional keys added'}.`);
|
|
239
|
+
}
|
|
240
|
+
// Detect IoT/devices
|
|
241
|
+
const iotMatches = findKeywords(description, IOT_KEYWORDS);
|
|
242
|
+
if (iotMatches.length > 0) {
|
|
243
|
+
const devicesIns = `${orgIns}.devices`;
|
|
244
|
+
insExamples.push(devicesIns);
|
|
245
|
+
const devicesNode = {
|
|
246
|
+
name: 'Device Fleet',
|
|
247
|
+
type: 'device',
|
|
248
|
+
ins: devicesIns,
|
|
249
|
+
algorithm: 'Ed25519',
|
|
250
|
+
rationale: 'IoT/device fleet — Ed25519 for constrained environments. Use fleet-level delegation.',
|
|
251
|
+
children: [],
|
|
252
|
+
};
|
|
253
|
+
root.children.push(devicesNode);
|
|
254
|
+
rationale.push('IoT/device keywords detected — fleet hierarchy with Ed25519 for constrained devices.');
|
|
255
|
+
}
|
|
256
|
+
// If no children detected, add sensible defaults
|
|
257
|
+
if (root.children.length === 0) {
|
|
258
|
+
root.children.push({
|
|
259
|
+
name: 'Production',
|
|
260
|
+
type: 'service',
|
|
261
|
+
ins: `${orgIns}.prod`,
|
|
262
|
+
algorithm: defaultAlgo,
|
|
263
|
+
rationale: 'Production signing identity — primary operational key.',
|
|
264
|
+
children: [],
|
|
265
|
+
}, {
|
|
266
|
+
name: 'Development',
|
|
267
|
+
type: 'service',
|
|
268
|
+
ins: `${orgIns}.dev`,
|
|
269
|
+
algorithm: 'Ed25519',
|
|
270
|
+
rationale: 'Development signing identity — isolated from production.',
|
|
271
|
+
children: [],
|
|
272
|
+
});
|
|
273
|
+
insExamples.push(`${orgIns}.prod`, `${orgIns}.dev`);
|
|
274
|
+
rationale.push('No specific departments or services detected — added default prod/dev split.');
|
|
275
|
+
}
|
|
276
|
+
// BSEC config hints
|
|
277
|
+
const bsecHints = [
|
|
278
|
+
`Create root slot: blink keygen --ins ${orgIns} --algorithm ${defaultAlgo}`,
|
|
279
|
+
];
|
|
280
|
+
if (hasGeoIsolation) {
|
|
281
|
+
bsecHints.push('Deploy separate BSEC instances per region for geographic isolation.');
|
|
282
|
+
}
|
|
283
|
+
if (hasAgentDelegation) {
|
|
284
|
+
bsecHints.push('Configure agent delegation scopes in BSEC slot policy to limit signing authority.');
|
|
285
|
+
}
|
|
286
|
+
if (hasRegulatory) {
|
|
287
|
+
bsecHints.push('Enable audit logging on all BSEC slots for regulatory compliance.');
|
|
288
|
+
bsecHints.push('Use ML-DSA-44 for compliance-critical signing paths.');
|
|
289
|
+
}
|
|
290
|
+
// Delegation model
|
|
291
|
+
const delegationModel = hasAgentDelegation
|
|
292
|
+
? 'Delegated: Parent keys can authorise child keys to sign within defined scopes. ' +
|
|
293
|
+
'Agents receive time-limited, scope-limited signing authority from their parent.'
|
|
294
|
+
: 'Hierarchical: Each level derives from its parent. Child keys cannot sign outside their namespace. ' +
|
|
295
|
+
'No delegation — each identity signs independently.';
|
|
296
|
+
const result = {
|
|
297
|
+
hierarchy: { root },
|
|
298
|
+
rationale,
|
|
299
|
+
bsec_config_hints: bsecHints,
|
|
300
|
+
ins_naming: {
|
|
301
|
+
pattern: `${orgIns}.<department>.<service|agent>`,
|
|
302
|
+
examples: insExamples,
|
|
303
|
+
},
|
|
304
|
+
delegation_model: delegationModel,
|
|
305
|
+
algorithm_recommendations: {
|
|
306
|
+
default: defaultAlgo,
|
|
307
|
+
high_value: highValueAlgo,
|
|
308
|
+
low_latency: 'Ed25519',
|
|
309
|
+
long_term_non_repudiation: 'ML-DSA-44',
|
|
310
|
+
},
|
|
311
|
+
};
|
|
312
|
+
return {
|
|
313
|
+
content: [{
|
|
314
|
+
type: 'text',
|
|
315
|
+
text: JSON.stringify(result, null, 2),
|
|
316
|
+
}],
|
|
317
|
+
};
|
|
318
|
+
}
|
|
319
|
+
//# sourceMappingURL=hierarchy.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hierarchy.js","sourceRoot":"","sources":["../../src/tools/hierarchy.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAcH,8EAA8E;AAC9E,mBAAmB;AACnB,8EAA8E;AAC9E,MAAM,aAAa,GAAsD;IACvE,QAAQ,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE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AAC,CAAC,iFAAiF;YACjF,iFAAiF;QACnF,CAAC,CAAC,oGAAoG;YACpG,oDAAoD,CAAC;IAEzD,MAAM,MAAM,GAAG;QACb,SAAS,EAAE,EAAE,IAAI,EAAE;QACnB,SAAS;QACT,iBAAiB,EAAE,SAAS;QAC5B,UAAU,EAAE;YACV,OAAO,EAAE,GAAG,MAAM,+BAA+B;YACjD,QAAQ,EAAE,WAAW;SACtB;QACD,gBAAgB,EAAE,eAAe;QACjC,yBAAyB,EAAE;YACzB,OAAO,EAAE,WAAW;YACpB,UAAU,EAAE,aAAa;YACzB,WAAW,EAAE,SAAS;YACtB,yBAAyB,EAAE,WAAW;SACvC;KACF,CAAC;IAEF,OAAO;QACL,OAAO,EAAE,CAAC;gBACR,IAAI,EAAE,MAAM;gBACZ,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;aACtC,CAAC;KACH,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* blink_lint tool handler.
|
|
3
|
+
*
|
|
4
|
+
* Analyses code for BLINK integration best practices using
|
|
5
|
+
* regex/pattern matching (no AST). Supports 8 rules.
|
|
6
|
+
*/
|
|
7
|
+
export declare function handleLint(args: Record<string, unknown>): {
|
|
8
|
+
content: Array<{
|
|
9
|
+
type: string;
|
|
10
|
+
text: string;
|
|
11
|
+
}>;
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=lint.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lint.d.ts","sourceRoot":"","sources":["../../src/tools/lint.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAmTH,wBAAgB,UAAU,CACxB,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAC5B;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CA6DpD"}
|