@ibgib/core-gib 0.1.59 → 0.1.61
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/CHANGELOG.md +12 -1
- package/dist/common/other/graph-helper.d.mts.map +1 -1
- package/dist/common/other/graph-helper.mjs +7 -6
- package/dist/common/other/graph-helper.mjs.map +1 -1
- package/dist/keystone/keystone-config-builder.d.mts +1 -2
- package/dist/keystone/keystone-config-builder.d.mts.map +1 -1
- package/dist/keystone/keystone-config-builder.mjs +4 -19
- package/dist/keystone/keystone-config-builder.mjs.map +1 -1
- package/dist/keystone/keystone-constants.d.mts +2 -0
- package/dist/keystone/keystone-constants.d.mts.map +1 -1
- package/dist/keystone/keystone-constants.mjs +2 -0
- package/dist/keystone/keystone-constants.mjs.map +1 -1
- package/dist/keystone/keystone-helpers.d.mts +5 -15
- package/dist/keystone/keystone-helpers.d.mts.map +1 -1
- package/dist/keystone/keystone-helpers.mjs +59 -73
- package/dist/keystone/keystone-helpers.mjs.map +1 -1
- package/dist/keystone/keystone-policy-types.d.mts +6 -4
- package/dist/keystone/keystone-policy-types.d.mts.map +1 -1
- package/dist/keystone/keystone-service-v1.d.mts.map +1 -1
- package/dist/keystone/keystone-service-v1.mjs +4 -8
- package/dist/keystone/keystone-service-v1.mjs.map +1 -1
- package/dist/keystone/keystone-service-v1.respec.mjs +182 -33
- package/dist/keystone/keystone-service-v1.respec.mjs.map +1 -1
- package/dist/keystone/keystone-types.d.mts +4 -11
- package/dist/keystone/keystone-types.d.mts.map +1 -1
- package/dist/keystone/policy/keystone-profile-builder.d.mts +25 -0
- package/dist/keystone/policy/keystone-profile-builder.d.mts.map +1 -0
- package/dist/keystone/policy/keystone-profile-builder.mjs +117 -0
- package/dist/keystone/policy/keystone-profile-builder.mjs.map +1 -0
- package/dist/keystone/policy/profiles/profile-high.json +84 -0
- package/dist/keystone/policy/profiles/profile-low.json +84 -0
- package/dist/keystone/policy/profiles/profile-medium.json +84 -0
- package/dist/keystone/policy/profiles/profile-session.json +84 -0
- package/dist/keystone/policy/profiles/profile-test.json +84 -0
- package/dist/keystone/policy/schemas/connect-pool.high.schema.json +23 -0
- package/dist/keystone/policy/schemas/connect-pool.low.schema.json +23 -0
- package/dist/keystone/policy/schemas/connect-pool.medium.schema.json +23 -0
- package/dist/keystone/policy/schemas/keystone.high.schema.json +26 -0
- package/dist/keystone/policy/schemas/keystone.low.schema.json +26 -0
- package/dist/keystone/policy/schemas/keystone.medium.schema.json +26 -0
- package/dist/keystone/policy/schemas/manage-pool.high.schema.json +23 -0
- package/dist/keystone/policy/schemas/manage-pool.low.schema.json +23 -0
- package/dist/keystone/policy/schemas/manage-pool.medium.schema.json +23 -0
- package/dist/keystone/policy/schemas/revoke-pool.high.schema.json +23 -0
- package/dist/keystone/policy/schemas/revoke-pool.low.schema.json +23 -0
- package/dist/keystone/policy/schemas/revoke-pool.medium.schema.json +23 -0
- package/dist/keystone/policy/schemas/sign-pool.high.schema.json +23 -0
- package/dist/keystone/policy/schemas/sign-pool.low.schema.json +23 -0
- package/dist/keystone/policy/schemas/sign-pool.medium.schema.json +23 -0
- package/dist/keystone/policy/schemas/sync-pool.high.schema.json +23 -0
- package/dist/keystone/policy/schemas/sync-pool.low.schema.json +23 -0
- package/dist/keystone/policy/schemas/sync-pool.medium.schema.json +23 -0
- package/dist/sync/sync-conflict-adv-multitimelines.withid.respec.d.mts +8 -0
- package/dist/sync/sync-conflict-adv-multitimelines.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-conflict-adv-multitimelines.withid.respec.mjs +582 -0
- package/dist/sync/sync-conflict-adv-multitimelines.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-conflict-basic-divergence.withid.respec.d.mts +7 -0
- package/dist/sync/sync-conflict-basic-divergence.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-conflict-basic-divergence.withid.respec.mjs +274 -0
- package/dist/sync/sync-conflict-basic-divergence.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-conflict-basic-multitimelines.withid.respec.d.mts +8 -0
- package/dist/sync/sync-conflict-basic-multitimelines.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-conflict-basic-multitimelines.withid.respec.mjs +322 -0
- package/dist/sync/sync-conflict-basic-multitimelines.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-conflict-text-merge.withid.respec.d.mts +7 -0
- package/dist/sync/sync-conflict-text-merge.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-conflict-text-merge.withid.respec.mjs +307 -0
- package/dist/sync/sync-conflict-text-merge.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-innerspace-constants.withid.respec.d.mts +8 -0
- package/dist/sync/sync-innerspace-constants.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-innerspace-constants.withid.respec.mjs +233 -0
- package/dist/sync/sync-innerspace-constants.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-innerspace-deep-updates.withid.respec.d.mts +7 -0
- package/dist/sync/sync-innerspace-deep-updates.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-innerspace-deep-updates.withid.respec.mjs +233 -0
- package/dist/sync/sync-innerspace-deep-updates.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-innerspace-dest-ahead.withid.respec.d.mts +7 -0
- package/dist/sync/sync-innerspace-dest-ahead.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-innerspace-dest-ahead.withid.respec.mjs +225 -0
- package/dist/sync/sync-innerspace-dest-ahead.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-innerspace-multiple-timelines.respec.mjs.map +1 -1
- package/dist/sync/sync-innerspace-multiple-timelines.withid.respec.d.mts +7 -0
- package/dist/sync/sync-innerspace-multiple-timelines.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-innerspace-multiple-timelines.withid.respec.mjs +235 -0
- package/dist/sync/sync-innerspace-multiple-timelines.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-innerspace-partial-update.withid.respec.d.mts +7 -0
- package/dist/sync/sync-innerspace-partial-update.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-innerspace-partial-update.withid.respec.mjs +211 -0
- package/dist/sync/sync-innerspace-partial-update.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-innerspace.withid.respec.d.mts +8 -0
- package/dist/sync/sync-innerspace.withid.respec.d.mts.map +1 -0
- package/dist/sync/sync-innerspace.withid.respec.mjs +260 -0
- package/dist/sync/sync-innerspace.withid.respec.mjs.map +1 -0
- package/dist/sync/sync-peer/sync-peer-innerspace/sync-peer-innerspace-v1.mjs +1 -1
- package/dist/sync/sync-peer/sync-peer-innerspace/sync-peer-innerspace-v1.mjs.map +1 -1
- package/dist/sync/sync-peer/sync-peer-types.d.mts +12 -1
- package/dist/sync/sync-peer/sync-peer-types.d.mts.map +1 -1
- package/dist/sync/sync-peer/sync-peer-v1.d.mts +7 -0
- package/dist/sync/sync-peer/sync-peer-v1.d.mts.map +1 -1
- package/dist/sync/sync-peer/sync-peer-v1.mjs +43 -1
- package/dist/sync/sync-peer/sync-peer-v1.mjs.map +1 -1
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-peer-websocket-receiver-v1.d.mts +2 -0
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-peer-websocket-receiver-v1.d.mts.map +1 -1
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-peer-websocket-receiver-v1.mjs +28 -9
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-peer-websocket-receiver-v1.mjs.map +1 -1
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-websocket-peer-helpers.d.mts +1 -1
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-websocket-peer-helpers.d.mts.map +1 -1
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-websocket-peer-helpers.mjs +5 -3
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-websocket-peer-helpers.mjs.map +1 -1
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-sender/sync-peer-websocket-sender-v1.d.mts +16 -0
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-sender/sync-peer-websocket-sender-v1.d.mts.map +1 -1
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-sender/sync-peer-websocket-sender-v1.mjs +223 -79
- package/dist/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-sender/sync-peer-websocket-sender-v1.mjs.map +1 -1
- package/dist/sync/sync-saga-context/sync-saga-context-helpers.d.mts.map +1 -1
- package/dist/sync/sync-saga-context/sync-saga-context-helpers.mjs +41 -2
- package/dist/sync/sync-saga-context/sync-saga-context-helpers.mjs.map +1 -1
- package/dist/sync/sync-saga-context/sync-saga-context-types.d.mts +4 -0
- package/dist/sync/sync-saga-context/sync-saga-context-types.d.mts.map +1 -1
- package/dist/sync/sync-saga-coordinator.d.mts +6 -0
- package/dist/sync/sync-saga-coordinator.d.mts.map +1 -1
- package/dist/sync/sync-saga-coordinator.mjs +213 -137
- package/dist/sync/sync-saga-coordinator.mjs.map +1 -1
- package/dist/sync/sync-withid.pingpong.respec.mjs +70 -2
- package/dist/sync/sync-withid.pingpong.respec.mjs.map +1 -1
- package/dist/timeline/timeline-api.d.mts.map +1 -1
- package/dist/timeline/timeline-api.mjs +1 -14
- package/dist/timeline/timeline-api.mjs.map +1 -1
- package/dist/witness/space/reconciliation-space/reconciliation-space-base.d.mts.map +1 -1
- package/dist/witness/space/reconciliation-space/reconciliation-space-base.mjs +0 -40
- package/dist/witness/space/reconciliation-space/reconciliation-space-base.mjs.map +1 -1
- package/dist/witness/space/reconciliation-space/reconciliation-space-helper.d.mts.map +1 -1
- package/dist/witness/space/reconciliation-space/reconciliation-space-helper.mjs +6 -6
- package/dist/witness/space/reconciliation-space/reconciliation-space-helper.mjs.map +1 -1
- package/ibgib-foundations.md +2 -1
- package/package.json +1 -1
- package/src/common/other/graph-helper.mts +7 -6
- package/src/keystone/README.md +19 -15
- package/src/keystone/docs/CRYPTANALYSIS.md +185 -0
- package/src/keystone/docs/architecture.md +24 -1
- package/src/keystone/docs/profiles.md +124 -0
- package/src/keystone/keystone-config-builder.mts +3 -21
- package/src/keystone/keystone-constants.mts +2 -0
- package/src/keystone/keystone-helpers.mts +74 -77
- package/src/keystone/keystone-policy-types.mts +6 -4
- package/src/keystone/keystone-service-v1.mts +4 -9
- package/src/keystone/keystone-service-v1.respec.mts +214 -32
- package/src/keystone/keystone-types.mts +5 -9
- package/src/keystone/policy/IMPLEMENTATION.md +60 -0
- package/src/keystone/policy/README.md +94 -0
- package/src/keystone/policy/keystone-profile-builder.mts +131 -0
- package/src/keystone/policy/profiles/profile-high.json +84 -0
- package/src/keystone/policy/profiles/profile-low.json +84 -0
- package/src/keystone/policy/profiles/profile-medium.json +84 -0
- package/src/keystone/policy/profiles/profile-session.json +84 -0
- package/src/keystone/policy/profiles/profile-test.json +84 -0
- package/src/keystone/policy/schemas/connect-pool.high.schema.json +23 -0
- package/src/keystone/policy/schemas/connect-pool.low.schema.json +23 -0
- package/src/keystone/policy/schemas/connect-pool.medium.schema.json +23 -0
- package/src/keystone/policy/schemas/keystone.high.schema.json +26 -0
- package/src/keystone/policy/schemas/keystone.low.schema.json +26 -0
- package/src/keystone/policy/schemas/keystone.medium.schema.json +26 -0
- package/src/keystone/policy/schemas/manage-pool.high.schema.json +23 -0
- package/src/keystone/policy/schemas/manage-pool.low.schema.json +23 -0
- package/src/keystone/policy/schemas/manage-pool.medium.schema.json +23 -0
- package/src/keystone/policy/schemas/revoke-pool.high.schema.json +23 -0
- package/src/keystone/policy/schemas/revoke-pool.low.schema.json +23 -0
- package/src/keystone/policy/schemas/revoke-pool.medium.schema.json +23 -0
- package/src/keystone/policy/schemas/sign-pool.high.schema.json +23 -0
- package/src/keystone/policy/schemas/sign-pool.low.schema.json +23 -0
- package/src/keystone/policy/schemas/sign-pool.medium.schema.json +23 -0
- package/src/keystone/policy/schemas/sync-pool.high.schema.json +23 -0
- package/src/keystone/policy/schemas/sync-pool.low.schema.json +23 -0
- package/src/keystone/policy/schemas/sync-pool.medium.schema.json +23 -0
- package/src/sync/docs/security-3b.md +92 -0
- package/src/sync/docs/security.md +139 -38
- package/src/sync/sync-conflict-adv-multitimelines.withid.respec.mts +706 -0
- package/src/sync/sync-conflict-basic-divergence.withid.respec.mts +321 -0
- package/src/sync/sync-conflict-basic-multitimelines.withid.respec.mts +374 -0
- package/src/sync/sync-conflict-text-merge.withid.respec.mts +347 -0
- package/src/sync/sync-innerspace-constants.withid.respec.mts +264 -0
- package/src/sync/sync-innerspace-deep-updates.withid.respec.mts +272 -0
- package/src/sync/sync-innerspace-dest-ahead.withid.respec.mts +266 -0
- package/src/sync/sync-innerspace-multiple-timelines.respec.mts +0 -1
- package/src/sync/sync-innerspace-multiple-timelines.withid.respec.mts +273 -0
- package/src/sync/sync-innerspace-partial-update.withid.respec.mts +249 -0
- package/src/sync/sync-innerspace.withid.respec.mts +265 -0
- package/src/sync/sync-peer/sync-peer-innerspace/sync-peer-innerspace-v1.mts +1 -1
- package/src/sync/sync-peer/sync-peer-types.mts +11 -1
- package/src/sync/sync-peer/sync-peer-v1.mts +47 -1
- package/src/sync/sync-peer/sync-peer-websocket/README.md +42 -0
- package/src/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-peer-websocket-receiver-v1.mts +26 -9
- package/src/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-receiver/sync-websocket-peer-helpers.mts +5 -3
- package/src/sync/sync-peer/sync-peer-websocket/sync-peer-websocket-sender/sync-peer-websocket-sender-v1.mts +242 -78
- package/src/sync/sync-saga-context/sync-saga-context-helpers.mts +46 -4
- package/src/sync/sync-saga-context/sync-saga-context-types.mts +5 -0
- package/src/sync/sync-saga-coordinator.mts +221 -137
- package/src/sync/sync-withid.pingpong.respec.mts +76 -3
- package/src/timeline/timeline-api.mts +1 -15
- package/src/timeline/timeline-api.respec.mts +3 -3
- package/src/witness/space/reconciliation-space/reconciliation-space-base.mts +0 -46
- package/src/witness/space/reconciliation-space/reconciliation-space-helper.mts +6 -5
- package/tsconfig.json +6 -1
- package/src/keystone/keystone-policy.schema.json +0 -51
- package/src/sync/docs/ping_pong_plan.md +0 -147
- package/src/witness/space/reconciliation-space/reconciliation-space-base.mts.OLD.md +0 -884
- package/src/witness/space/reconciliation-space/reconciliation-space-helper.mts.OLD.md +0 -125
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "MediumSecurityKeystoneProfile",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"metadata": {
|
|
7
|
+
"type": "object",
|
|
8
|
+
"properties": {
|
|
9
|
+
"name": { "type": "string" },
|
|
10
|
+
"securityLevel": { "type": "string", "const": "medium" }
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
"pools": {
|
|
14
|
+
"type": "object",
|
|
15
|
+
"properties": {
|
|
16
|
+
"sync": { "$ref": "./sync-pool.medium.schema.json" },
|
|
17
|
+
"manage": { "$ref": "./manage-pool.medium.schema.json" },
|
|
18
|
+
"revoke": { "$ref": "./revoke-pool.medium.schema.json" },
|
|
19
|
+
"connect": { "$ref": "./connect-pool.medium.schema.json" },
|
|
20
|
+
"sign": { "$ref": "./sign-pool.medium.schema.json" }
|
|
21
|
+
},
|
|
22
|
+
"required": ["sync", "manage", "revoke", "connect", "sign"]
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"required": ["pools"]
|
|
26
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "HighSecurityManagePool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "manage" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "manage" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-512" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 4 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 2000 },
|
|
14
|
+
"replenish": { "type": "string", "enum": ["top-up", "replace-all"] },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 10 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 10 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 16 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "LowSecurityManagePool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "manage" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "manage" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-256" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 2 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 10 },
|
|
14
|
+
"replenish": { "type": "string", "enum": ["top-up", "replace-all"] },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 1 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 1 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 3 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "MediumSecurityManagePool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "manage" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "manage" } },
|
|
8
|
+
"algo": { "type": "string", "enum": ["SHA-256", "SHA-512"] },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 2 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 500 },
|
|
14
|
+
"replenish": { "type": "string", "enum": ["top-up", "replace-all"] },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 5 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 5 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 10 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "HighSecurityRevokePool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "revoke" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "revoke" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-512" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 20 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 2000 },
|
|
14
|
+
"replenish": { "type": "string", "const": "delete-all" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 50 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 50 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 0 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "LowSecurityRevokePool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "revoke" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "revoke" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-256" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 5 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 12 },
|
|
14
|
+
"replenish": { "type": "string", "const": "delete-all" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 3 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 3 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 0 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "MediumSecurityRevokePool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "revoke" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "revoke" } },
|
|
8
|
+
"algo": { "type": "string", "enum": ["SHA-256", "SHA-512"] },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 10 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 200 },
|
|
14
|
+
"replenish": { "type": "string", "const": "delete-all" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 20 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 20 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 0 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "HighSecuritySignPool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "default" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "sign" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-512" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 4 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 1000 },
|
|
14
|
+
"replenish": { "type": "string", "const": "top-up" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 10 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 10 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 16 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "LowSecuritySignPool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "default" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "sign" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-256" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 2 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 20 },
|
|
14
|
+
"replenish": { "type": "string", "const": "top-up" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 1 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 1 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 3 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "MediumSecuritySignPool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "default" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "sign" } },
|
|
8
|
+
"algo": { "type": "string", "enum": ["SHA-256", "SHA-512"] },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 2 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 200 },
|
|
14
|
+
"replenish": { "type": "string", "const": "top-up" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 5 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 5 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 10 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "HighSecuritySyncPool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "sync" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "sync" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-512" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 4 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 2000 },
|
|
14
|
+
"replenish": { "type": "string", "const": "top-up" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 10 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 10 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 16 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "LowSecuritySyncPool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "sync" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "sync" } },
|
|
8
|
+
"algo": { "type": "string", "const": "SHA-256" },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 1 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 12 },
|
|
14
|
+
"replenish": { "type": "string", "const": "top-up" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 1 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 1 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 3 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "MediumSecuritySyncPool",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"properties": {
|
|
6
|
+
"id": { "type": "string", "const": "sync" },
|
|
7
|
+
"allowedVerbs": { "type": "array", "items": { "const": "sync" } },
|
|
8
|
+
"algo": { "type": "string", "enum": ["SHA-256", "SHA-512"] },
|
|
9
|
+
"rounds": { "type": "integer", "minimum": 2 },
|
|
10
|
+
"behavior": {
|
|
11
|
+
"type": "object",
|
|
12
|
+
"properties": {
|
|
13
|
+
"size": { "type": "integer", "minimum": 500 },
|
|
14
|
+
"replenish": { "type": "string", "const": "top-up" },
|
|
15
|
+
"selectSequentially": { "type": "integer", "minimum": 5 },
|
|
16
|
+
"selectRandomly": { "type": "integer", "minimum": 5 },
|
|
17
|
+
"targetBindingCount": { "type": "integer", "minimum": 10 }
|
|
18
|
+
},
|
|
19
|
+
"required": ["size", "replenish", "selectSequentially", "selectRandomly", "targetBindingCount"]
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": ["id", "allowedVerbs", "algo", "rounds", "behavior"]
|
|
23
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
# Implementation Plan: Phase 3B — Basic Single-Timeline Sync with Identity (Integrated)
|
|
2
|
+
|
|
3
|
+
This document outlines the implementation plan for Phase 3B of identity integration, focusing on integrating the cryptographic session identity into the WebSocket sync peer architecture, and wiring up the Row 3B dev-tools test buttons.
|
|
4
|
+
|
|
5
|
+
## 1. Goal
|
|
6
|
+
The goal of Phase 3B is to achieve successful end-to-end synchronization of a test ibgib `X` over a stateful WebSocket connection using asymmetric session identity validation.
|
|
7
|
+
At the end of the sync saga:
|
|
8
|
+
- Both sender and receiver durable spaces must contain the same evolved Domain Keystone (I1).
|
|
9
|
+
- Both spaces must contain the full session identity keystone (S) graph evolved to the correct turn count ($n = 3$, or potentially $n = 4$ depending on exact commit phase timeline evolution).
|
|
10
|
+
- Both spaces must contain the identical target ibgib `X` dependency graph.
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## 2. Technical Challenge: Asymmetric Authentication in WebSocket Peers
|
|
15
|
+
In V1, only the sender (Alice) signs the synchronization context. The receiver (Bob) skips signing the response context (`skipSign: true`), relying on transport-level security (TLS) for the return path.
|
|
16
|
+
Consequently:
|
|
17
|
+
- Alice's request context contains a `signedSessionIdentity`.
|
|
18
|
+
- Bob's response context has `signedSessionIdentity` set to `undefined`.
|
|
19
|
+
|
|
20
|
+
### Current Issue in `SyncPeerWebSocketSender_V1`
|
|
21
|
+
In `SyncPeerWebSocketSender_V1.handleRuntimeMessage`, the sender currently attempts to authenticate Bob's response context:
|
|
22
|
+
```typescript
|
|
23
|
+
if (msg.type === SyncWebSocketMsgType.sync_frame_response) {
|
|
24
|
+
const responseContext = msg.context as SyncSagaContextIbGib_V1;
|
|
25
|
+
|
|
26
|
+
// Validate and authenticate Bob's response context first
|
|
27
|
+
await this.authenticateAndValidate({ context: responseContext });
|
|
28
|
+
```
|
|
29
|
+
Because `authenticateAndValidate` calls `authenticateContextIntrinsically` which expects a signature when `sagaFrame.data.sessionIdentityTjpAddr` is present, this call will throw an error since Bob's response context has no `signedSessionIdentity`.
|
|
30
|
+
|
|
31
|
+
### Solution
|
|
32
|
+
Change `SyncPeerWebSocketSender_V1.handleRuntimeMessage` to run structural/intrinsic validation instead of full authentication on the response context:
|
|
33
|
+
```typescript
|
|
34
|
+
// Ensure the response context and saga frame are valid structurally
|
|
35
|
+
const validationErrors = await validateContextAndSagaFrame({ context: responseContext });
|
|
36
|
+
if (validationErrors.length > 0) {
|
|
37
|
+
throw new Error(`Invalid response context received. Errors: ${validationErrors.join(', ')}`);
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
The client-side `SyncSagaCoordinator` will then run the turn-by-turn continuation, sequence, and identity validation checks via `validateReturnContext(...)`. This provides a robust stopgap validation for V1 before the receiver-side signing is fully implemented in future versions.
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## 3. UI Integration: Dev Tools Row 3B
|
|
46
|
+
We will wire up the three buttons in `apps/space-gib/src/client/dev-tools.mts` under the `init3bPlaceholder` placeholder handler:
|
|
47
|
+
|
|
48
|
+
### 3.1. `btn-3b-setup`
|
|
49
|
+
- **Actions**:
|
|
50
|
+
1. Generates a new long-lived Domain Keystone (I) for Alice using master secret `'test-sender-secret-phase3'` and unique salts (`'senderidentitysyncsaltphase3'`, `'senderidentitymanagesaltphase3'`).
|
|
51
|
+
2. Registers the genesis Domain Keystone (I) on the server via `apiBridge.postGenesisKeystone(domainI)`.
|
|
52
|
+
3. Creates a local dummy Target IbGib (X) with distinct test data: `{ hello: 'world3', random: Math.random() }`.
|
|
53
|
+
4. Stores `domainI`, `domainIMasterSecret`, and `targetX` in `debugState`.
|
|
54
|
+
5. Updates button text to `✓ 3B Setup Complete` and enables `btn-3b-sync`.
|
|
55
|
+
|
|
56
|
+
### 3.2. `btn-3b-sync`
|
|
57
|
+
- **Actions**:
|
|
58
|
+
1. Instantiates `SyncPeerWebSocketSender_V1` targeting the server's WS and evolution endpoints.
|
|
59
|
+
2. Initializes peer options with Alice's identity, secret, and a newly generated `sagaId`.
|
|
60
|
+
3. Instantiates `SyncSagaCoordinator`.
|
|
61
|
+
4. Calls `coordinator.sync(...)` to synchronize Target X to the server.
|
|
62
|
+
5. Awaits completion (`await syncSaga.done`). This must run without errors.
|
|
63
|
+
6. Updates button text to `✓ 3B Sync Run` and enables `btn-3b-check`.
|
|
64
|
+
|
|
65
|
+
### 3.3. `btn-3b-check`
|
|
66
|
+
- **Actions**:
|
|
67
|
+
1. Resolves the client's latest Target X address and fetches its local dependency graph.
|
|
68
|
+
2. Resolves the server's latest Target X address and fetches its server-side dependency graph using a new API bridge helper.
|
|
69
|
+
3. Asserts the client and server Target X graphs are equivalent:
|
|
70
|
+
- The latest address of X is identical.
|
|
71
|
+
- Graph node counts are identical.
|
|
72
|
+
- All keys and values match.
|
|
73
|
+
4. Resolves the latest session identity (S) address and asserts it evolved to `n = 2` (Init at $n=0$, Connect Handshake at $n=1$, Sync Context Sign at $n=2$).
|
|
74
|
+
5. Verifies the latest S address and graph are identical on both client and server.
|
|
75
|
+
6. Verifies the evolved Domain Keystone (I1) is present in both client and server spaces.
|
|
76
|
+
7. If all checks pass, logs `🎉 ALL PHASE 3B CHECKS PASSED FLAWLESSLY! ✓` and updates button text to `✓ 3B All Passed`.
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
## 4. Concrete Checklist
|
|
81
|
+
|
|
82
|
+
### [ ] API Bridge Extension
|
|
83
|
+
- [ ] Add `getIbGibGraph(domainAddr, ibGibAddr)` to `SpaceGibApiBridge` (`apps/space-gib/src/client/api/space-gib-api-bridge.mts`) to retrieve dependency graphs with `getGraph=true`.
|
|
84
|
+
|
|
85
|
+
### [ ] WebSocket Peer Adjustments
|
|
86
|
+
- [ ] Modify `SyncPeerWebSocketSender_V1.handleRuntimeMessage` to bypass `authenticateAndValidate` on Bob's response context, using `validateContextAndSagaFrame` instead.
|
|
87
|
+
|
|
88
|
+
### [ ] Dev Tools UI (Row 3B) Wiring
|
|
89
|
+
- [ ] Implement `init3bSetupButton` inside `dev-tools.mts`.
|
|
90
|
+
- [ ] Implement `init3bSyncButton` inside `dev-tools.mts`.
|
|
91
|
+
- [ ] Implement `init3bCheckButton` inside `dev-tools.mts`.
|
|
92
|
+
- [ ] Update `initDevTools` to initialize the new button handlers and remove `init3bPlaceholder`.
|