@sanctuary-framework/mcp-server 0.5.3 → 0.5.5
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/cli.cjs +5990 -5700
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.js +5996 -5706
- package/dist/cli.js.map +1 -1
- package/dist/index.cjs +7 -37
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +7 -37
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -231,7 +231,7 @@ function defaultConfig() {
|
|
|
231
231
|
}
|
|
232
232
|
},
|
|
233
233
|
disclosure: {
|
|
234
|
-
proof_system: "
|
|
234
|
+
proof_system: "schnorr-pedersen",
|
|
235
235
|
default_policy: "minimum-necessary"
|
|
236
236
|
},
|
|
237
237
|
reputation: {
|
|
@@ -345,7 +345,7 @@ function validateConfig(config) {
|
|
|
345
345
|
`Unimplemented config value: execution.environment = "${config.execution.environment}". Only ${[...implementedEnvironment].map((v) => `"${v}"`).join(", ")} are currently implemented. Using an unimplemented environment would silently degrade security.`
|
|
346
346
|
);
|
|
347
347
|
}
|
|
348
|
-
const implementedProofSystem = /* @__PURE__ */ new Set(["commitment-only"]);
|
|
348
|
+
const implementedProofSystem = /* @__PURE__ */ new Set(["schnorr-pedersen", "commitment-only"]);
|
|
349
349
|
if (!implementedProofSystem.has(config.disclosure.proof_system)) {
|
|
350
350
|
errors.push(
|
|
351
351
|
`Unimplemented config value: disclosure.proof_system = "${config.disclosure.proof_system}". Only ${[...implementedProofSystem].map((v) => `"${v}"`).join(", ")} is currently implemented. Using an unimplemented proof system would silently degrade security.`
|
|
@@ -7431,15 +7431,6 @@ function generateSHR(identityId, opts) {
|
|
|
7431
7431
|
mitigation: "TEE attestation planned for a future release"
|
|
7432
7432
|
});
|
|
7433
7433
|
}
|
|
7434
|
-
if (config.disclosure.proof_system === "commitment-only") {
|
|
7435
|
-
degradations.push({
|
|
7436
|
-
layer: "l3",
|
|
7437
|
-
code: "COMMITMENT_ONLY",
|
|
7438
|
-
severity: "info",
|
|
7439
|
-
description: "Commitment schemes only (no ZK proofs)",
|
|
7440
|
-
mitigation: "ZK proof support planned for future release"
|
|
7441
|
-
});
|
|
7442
|
-
}
|
|
7443
7434
|
const body = {
|
|
7444
7435
|
shr_version: "1.0",
|
|
7445
7436
|
implementation: {
|
|
@@ -7465,9 +7456,9 @@ function generateSHR(identityId, opts) {
|
|
|
7465
7456
|
attestation_available: config.execution.attestation
|
|
7466
7457
|
},
|
|
7467
7458
|
l3: {
|
|
7468
|
-
status:
|
|
7459
|
+
status: "active",
|
|
7469
7460
|
proof_system: config.disclosure.proof_system,
|
|
7470
|
-
selective_disclosure:
|
|
7461
|
+
selective_disclosure: true
|
|
7471
7462
|
},
|
|
7472
7463
|
l4: {
|
|
7473
7464
|
status: "active",
|
|
@@ -7680,7 +7671,7 @@ function extractAuthorizationSignals(body) {
|
|
|
7680
7671
|
behavioral_baseline_active: false,
|
|
7681
7672
|
// Would need explicit field in SHR v1.1
|
|
7682
7673
|
identity_verified: l1.identity_type === "ed25519" || l1.identity_type !== "none",
|
|
7683
|
-
zero_knowledge_capable: l3.status === "active"
|
|
7674
|
+
zero_knowledge_capable: l3.status === "active",
|
|
7684
7675
|
selective_disclosure_active: l3.selective_disclosure,
|
|
7685
7676
|
reputation_portable: l4.reputation_portable,
|
|
7686
7677
|
handshake_capable: body.capabilities.handshake
|
|
@@ -7758,14 +7749,6 @@ function generateAuthorizationConstraints(body, _degradations) {
|
|
|
7758
7749
|
priority: "high"
|
|
7759
7750
|
});
|
|
7760
7751
|
}
|
|
7761
|
-
if (layers.l3.proof_system === "commitment-only") {
|
|
7762
|
-
constraints.push({
|
|
7763
|
-
type: "restricted_scope",
|
|
7764
|
-
description: "No zero-knowledge proofs available \u2014 entire state context may be visible",
|
|
7765
|
-
rationale: "Proof system is commitment-only (no ZK)",
|
|
7766
|
-
priority: "medium"
|
|
7767
|
-
});
|
|
7768
|
-
}
|
|
7769
7752
|
if (layers.l4.status === "degraded") {
|
|
7770
7753
|
constraints.push({
|
|
7771
7754
|
type: "known_agents_only",
|
|
@@ -11893,11 +11876,6 @@ async function createSanctuaryServer(options) {
|
|
|
11893
11876
|
degradations.push(
|
|
11894
11877
|
"L2 isolation is process-level only; no TEE available"
|
|
11895
11878
|
);
|
|
11896
|
-
if (config.disclosure.proof_system === "commitment-only") {
|
|
11897
|
-
degradations.push(
|
|
11898
|
-
"L3 proofs are commitment-based only; ZK proofs not yet available"
|
|
11899
|
-
);
|
|
11900
|
-
}
|
|
11901
11879
|
return toolResult({
|
|
11902
11880
|
attestation: {
|
|
11903
11881
|
environment_type: config.execution.environment,
|
|
@@ -11923,7 +11901,7 @@ async function createSanctuaryServer(options) {
|
|
|
11923
11901
|
l1_state_encrypted: true,
|
|
11924
11902
|
l2_execution_isolated: false,
|
|
11925
11903
|
l2_isolation_type: "process-level",
|
|
11926
|
-
l3_proofs_available:
|
|
11904
|
+
l3_proofs_available: true,
|
|
11927
11905
|
l4_reputation_active: true,
|
|
11928
11906
|
overall_level: "mvs",
|
|
11929
11907
|
degradations
|
|
@@ -11946,14 +11924,6 @@ async function createSanctuaryServer(options) {
|
|
|
11946
11924
|
severity: "warning",
|
|
11947
11925
|
mitigation: "TEE support planned for a future release"
|
|
11948
11926
|
});
|
|
11949
|
-
if (config.disclosure.proof_system === "commitment-only") {
|
|
11950
|
-
degradations.push({
|
|
11951
|
-
layer: "l3",
|
|
11952
|
-
description: "Commitment schemes only (no ZK proofs)",
|
|
11953
|
-
severity: "info",
|
|
11954
|
-
mitigation: "ZK proof support planned for v0.2.0"
|
|
11955
|
-
});
|
|
11956
|
-
}
|
|
11957
11927
|
return toolResult({
|
|
11958
11928
|
status: degradations.some((d) => d.severity === "critical") ? "compromised" : degradations.some((d) => d.severity === "warning") ? "degraded" : "healthy",
|
|
11959
11929
|
storage_bytes: storageSizeBytes,
|
|
@@ -11972,7 +11942,7 @@ async function createSanctuaryServer(options) {
|
|
|
11972
11942
|
last_attestation: (/* @__PURE__ */ new Date()).toISOString()
|
|
11973
11943
|
},
|
|
11974
11944
|
l3: {
|
|
11975
|
-
status:
|
|
11945
|
+
status: "active",
|
|
11976
11946
|
proof_system: config.disclosure.proof_system,
|
|
11977
11947
|
circuits_loaded: 0,
|
|
11978
11948
|
proofs_generated_total: 0
|