@openvtc/trust-tasks 0.27.0 → 0.27.2
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 +267 -0
- package/dist/_runtime/freshness.d.ts +3 -1
- package/dist/_runtime/freshness.d.ts.map +1 -1
- package/dist/_runtime/freshness.js +4 -2
- package/dist/_runtime/freshness.js.map +1 -1
- package/dist/_shared/components.d.ts +361 -24
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/device/list/0.1/payload.d.ts +4 -4
- package/dist/device/list/0.1/payload.d.ts.map +1 -1
- package/dist/device/list/0.1/payload.js +4 -2
- package/dist/device/list/0.1/payload.js.map +1 -1
- package/dist/device/list/0.2/payload.d.ts +4 -4
- package/dist/device/list/0.2/payload.d.ts.map +1 -1
- package/dist/device/list/0.2/payload.js +4 -2
- package/dist/device/list/0.2/payload.js.map +1 -1
- package/dist/device/register/0.1/payload.d.ts +4 -4
- package/dist/device/register/0.1/payload.d.ts.map +1 -1
- package/dist/device/register/0.1/payload.js +4 -2
- package/dist/device/register/0.1/payload.js.map +1 -1
- package/dist/device/register/0.2/payload.d.ts +4 -4
- package/dist/device/register/0.2/payload.d.ts.map +1 -1
- package/dist/device/register/0.2/payload.js +4 -2
- package/dist/device/register/0.2/payload.js.map +1 -1
- package/dist/index.d.ts +31 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +31 -0
- package/dist/index.js.map +1 -1
- package/dist/rooms/_shared/0.1/room.d.ts +1 -1
- package/dist/rooms/_shared/0.1/room.d.ts.map +1 -1
- package/dist/rooms/create/0.2/payload.d.ts +534 -0
- package/dist/rooms/create/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/create/0.2/payload.js +293 -0
- package/dist/rooms/create/0.2/payload.js.map +1 -0
- package/dist/rooms/epoch/chain/0.2/payload.d.ts +534 -0
- package/dist/rooms/epoch/chain/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/epoch/chain/0.2/payload.js +292 -0
- package/dist/rooms/epoch/chain/0.2/payload.js.map +1 -0
- package/dist/rooms/epoch/prune/0.2/payload.d.ts +467 -0
- package/dist/rooms/epoch/prune/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/epoch/prune/0.2/payload.js +251 -0
- package/dist/rooms/epoch/prune/0.2/payload.js.map +1 -0
- package/dist/rooms/info/0.2/payload.d.ts +1129 -0
- package/dist/rooms/info/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/info/0.2/payload.js +618 -0
- package/dist/rooms/info/0.2/payload.js.map +1 -0
- package/dist/rooms/keys/backfill/0.2/payload.d.ts +380 -0
- package/dist/rooms/keys/backfill/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/keys/backfill/0.2/payload.js +197 -0
- package/dist/rooms/keys/backfill/0.2/payload.js.map +1 -0
- package/dist/rooms/keys/browse/0.1/payload.d.ts +4 -4
- package/dist/rooms/keys/browse/0.1/payload.js +2 -2
- package/dist/rooms/keys/browse/0.1/payload.js.map +1 -1
- package/dist/rooms/keys/browse/0.2/payload.d.ts +941 -0
- package/dist/rooms/keys/browse/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/keys/browse/0.2/payload.js +558 -0
- package/dist/rooms/keys/browse/0.2/payload.js.map +1 -0
- package/dist/rooms/keys/chain/0.2/payload.d.ts +450 -0
- package/dist/rooms/keys/chain/0.2/payload.d.ts.map +1 -0
- package/dist/rooms/keys/chain/0.2/payload.js +248 -0
- package/dist/rooms/keys/chain/0.2/payload.js.map +1 -0
- package/dist/rooms/keys/profile/read/0.1/payload.d.ts +4 -4
- package/dist/rooms/keys/profile/read/0.1/payload.js +2 -2
- package/dist/rooms/keys/profile/read/0.1/payload.js.map +1 -1
- package/dist/rooms/keys/read/0.1/payload.d.ts +4 -4
- package/dist/rooms/keys/read/0.1/payload.js +2 -2
- package/dist/rooms/keys/read/0.1/payload.js.map +1 -1
- package/dist/rooms/owner/anchor/0.1/payload.d.ts +4 -4
- package/dist/rooms/owner/anchor/0.1/payload.js +2 -2
- package/dist/rooms/owner/anchor/0.1/payload.js.map +1 -1
- package/dist/rooms/records/get/0.1/payload.d.ts +4 -4
- package/dist/rooms/records/get/0.1/payload.js +2 -2
- package/dist/rooms/records/get/0.1/payload.js.map +1 -1
- package/dist/rooms/records/get/0.2/payload.d.ts +4 -4
- package/dist/rooms/records/get/0.2/payload.js +2 -2
- package/dist/rooms/records/get/0.2/payload.js.map +1 -1
- package/dist/rooms/records/list/0.1/payload.d.ts +4 -4
- package/dist/rooms/records/list/0.1/payload.js +2 -2
- package/dist/rooms/records/list/0.1/payload.js.map +1 -1
- package/dist/rooms/records/list/0.2/payload.d.ts +4 -4
- package/dist/rooms/records/list/0.2/payload.js +2 -2
- package/dist/rooms/records/list/0.2/payload.js.map +1 -1
- package/dist/rooms/records/list/0.3/payload.d.ts +970 -0
- package/dist/rooms/records/list/0.3/payload.d.ts.map +1 -0
- package/dist/rooms/records/list/0.3/payload.js +526 -0
- package/dist/rooms/records/list/0.3/payload.js.map +1 -0
- package/dist/rooms/records/prune/0.1/payload.d.ts +706 -0
- package/dist/rooms/records/prune/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/records/prune/0.1/payload.js +374 -0
- package/dist/rooms/records/prune/0.1/payload.js.map +1 -0
- package/dist/rooms/records/put/0.3/payload.d.ts +1212 -0
- package/dist/rooms/records/put/0.3/payload.d.ts.map +1 -0
- package/dist/rooms/records/put/0.3/payload.js +646 -0
- package/dist/rooms/records/put/0.3/payload.js.map +1 -0
- package/dist/rooms/records/retention/set/0.1/payload.d.ts +521 -0
- package/dist/rooms/records/retention/set/0.1/payload.d.ts.map +1 -0
- package/dist/rooms/records/retention/set/0.1/payload.js +276 -0
- package/dist/rooms/records/retention/set/0.1/payload.js.map +1 -0
- package/dist/vault/credentials/present/0.1/payload.d.ts +407 -0
- package/dist/vault/credentials/present/0.1/payload.d.ts.map +1 -0
- package/dist/vault/credentials/present/0.1/payload.js +217 -0
- package/dist/vault/credentials/present/0.1/payload.js.map +1 -0
- package/dist/voting/_shared/0.1/voting.d.ts +1 -1
- package/dist/voting/_shared/0.1/voting.d.ts.map +1 -1
- package/dist/voting/board/read/0.1/payload.d.ts +58 -2
- package/dist/voting/board/read/0.1/payload.d.ts.map +1 -1
- package/dist/voting/board/read/0.1/payload.js +36 -0
- package/dist/voting/board/read/0.1/payload.js.map +1 -1
- package/dist/voting/trustees/authorize/0.1/payload.d.ts +617 -0
- package/dist/voting/trustees/authorize/0.1/payload.d.ts.map +1 -0
- package/dist/voting/trustees/authorize/0.1/payload.js +386 -0
- package/dist/voting/trustees/authorize/0.1/payload.js.map +1 -0
- package/dist/voting/trustees/status/0.1/payload.d.ts +106 -2
- package/dist/voting/trustees/status/0.1/payload.d.ts.map +1 -1
- package/dist/voting/trustees/status/0.1/payload.js +48 -0
- package/dist/voting/trustees/status/0.1/payload.js.map +1 -1
- package/dist/vta/pcs/trustee/deal/0.2/payload.d.ts +1832 -0
- package/dist/vta/pcs/trustee/deal/0.2/payload.d.ts.map +1 -0
- package/dist/vta/pcs/trustee/deal/0.2/payload.js +1077 -0
- package/dist/vta/pcs/trustee/deal/0.2/payload.js.map +1 -0
- package/dist/vta/pcs/trustee/decrypt/0.2/payload.d.ts +758 -0
- package/dist/vta/pcs/trustee/decrypt/0.2/payload.d.ts.map +1 -0
- package/dist/vta/pcs/trustee/decrypt/0.2/payload.js +423 -0
- package/dist/vta/pcs/trustee/decrypt/0.2/payload.js.map +1 -0
- package/dist/vta/pcs/trustee/justify/0.2/payload.d.ts +1867 -0
- package/dist/vta/pcs/trustee/justify/0.2/payload.d.ts.map +1 -0
- package/dist/vta/pcs/trustee/justify/0.2/payload.js +1095 -0
- package/dist/vta/pcs/trustee/justify/0.2/payload.js.map +1 -0
- package/dist/vta/pcs/trustee/keys/0.2/payload.d.ts +1912 -0
- package/dist/vta/pcs/trustee/keys/0.2/payload.d.ts.map +1 -0
- package/dist/vta/pcs/trustee/keys/0.2/payload.js +1115 -0
- package/dist/vta/pcs/trustee/keys/0.2/payload.js.map +1 -0
- package/dist/vta/pcs/vote-encrypted/0.2/payload.d.ts +2228 -0
- package/dist/vta/pcs/vote-encrypted/0.2/payload.d.ts.map +1 -0
- package/dist/vta/pcs/vote-encrypted/0.2/payload.js +1300 -0
- package/dist/vta/pcs/vote-encrypted/0.2/payload.js.map +1 -0
- package/dist/vta/webvh/dids/create/1.2/payload.d.ts +961 -0
- package/dist/vta/webvh/dids/create/1.2/payload.d.ts.map +1 -0
- package/dist/vta/webvh/dids/create/1.2/payload.js +480 -0
- package/dist/vta/webvh/dids/create/1.2/payload.js.map +1 -0
- package/dist/vtc/_shared/0.1/room-migration.d.ts +16 -0
- package/dist/vtc/_shared/0.1/room-migration.d.ts.map +1 -0
- package/dist/vtc/_shared/0.1/room-migration.js +6 -0
- package/dist/vtc/_shared/0.1/room-migration.js.map +1 -0
- package/dist/vtc/_shared/0.1/room-storage.d.ts +1 -1
- package/dist/vtc/_shared/0.1/room-storage.d.ts.map +1 -1
- package/dist/vtc/_shared/0.2/room-storage.d.ts +16 -0
- package/dist/vtc/_shared/0.2/room-storage.d.ts.map +1 -0
- package/dist/vtc/_shared/0.2/room-storage.js +6 -0
- package/dist/vtc/_shared/0.2/room-storage.js.map +1 -0
- package/dist/vtc/admin/events/_shared/0.4/topic.d.ts +31 -0
- package/dist/vtc/admin/events/_shared/0.4/topic.d.ts.map +1 -0
- package/dist/vtc/admin/events/_shared/0.4/topic.js +6 -0
- package/dist/vtc/admin/events/_shared/0.4/topic.js.map +1 -0
- package/dist/vtc/admin/events/event/0.4/payload.d.ts +172 -0
- package/dist/vtc/admin/events/event/0.4/payload.d.ts.map +1 -0
- package/dist/vtc/admin/events/event/0.4/payload.js +103 -0
- package/dist/vtc/admin/events/event/0.4/payload.js.map +1 -0
- package/dist/vtc/admin/events/subscribe/0.4/payload.d.ts +409 -0
- package/dist/vtc/admin/events/subscribe/0.4/payload.d.ts.map +1 -0
- package/dist/vtc/admin/events/subscribe/0.4/payload.js +238 -0
- package/dist/vtc/admin/events/subscribe/0.4/payload.js.map +1 -0
- package/dist/vtc/elections/show/0.1/payload.d.ts +86 -2
- package/dist/vtc/elections/show/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/elections/show/0.1/payload.js +40 -0
- package/dist/vtc/elections/show/0.1/payload.js.map +1 -1
- package/dist/vtc/rooms/get/0.2/payload.d.ts +1966 -0
- package/dist/vtc/rooms/get/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/rooms/get/0.2/payload.js +976 -0
- package/dist/vtc/rooms/get/0.2/payload.js.map +1 -0
- package/dist/vtc/rooms/storage/migrate/0.2/payload.d.ts +595 -0
- package/dist/vtc/rooms/storage/migrate/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/rooms/storage/migrate/0.2/payload.js +336 -0
- package/dist/vtc/rooms/storage/migrate/0.2/payload.js.map +1 -0
- package/dist/vtc/storage/configs/create/0.1/payload.d.ts +1 -1
- package/dist/vtc/storage/configs/create/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/storage/configs/create/0.2/payload.d.ts +1360 -0
- package/dist/vtc/storage/configs/create/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/storage/configs/create/0.2/payload.js +783 -0
- package/dist/vtc/storage/configs/create/0.2/payload.js.map +1 -0
- package/dist/vtc/storage/configs/get/0.1/payload.d.ts +1 -1
- package/dist/vtc/storage/configs/get/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/storage/configs/get/0.2/payload.d.ts +1854 -0
- package/dist/vtc/storage/configs/get/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/storage/configs/get/0.2/payload.js +1075 -0
- package/dist/vtc/storage/configs/get/0.2/payload.js.map +1 -0
- package/dist/vtc/storage/configs/list/0.1/payload.d.ts +1 -1
- package/dist/vtc/storage/configs/list/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/storage/configs/list/0.2/payload.d.ts +1955 -0
- package/dist/vtc/storage/configs/list/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/storage/configs/list/0.2/payload.js +1125 -0
- package/dist/vtc/storage/configs/list/0.2/payload.js.map +1 -0
- package/dist/vtc/storage/configs/update/0.1/payload.d.ts +1 -1
- package/dist/vtc/storage/configs/update/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/storage/configs/update/0.2/payload.d.ts +1362 -0
- package/dist/vtc/storage/configs/update/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/storage/configs/update/0.2/payload.js +782 -0
- package/dist/vtc/storage/configs/update/0.2/payload.js.map +1 -0
- package/dist/vtc/storage/credentials/set/0.1/payload.d.ts +1 -1
- package/dist/vtc/storage/credentials/set/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/storage/credentials/set/0.2/payload.d.ts +979 -0
- package/dist/vtc/storage/credentials/set/0.2/payload.d.ts.map +1 -0
- package/dist/vtc/storage/credentials/set/0.2/payload.js +573 -0
- package/dist/vtc/storage/credentials/set/0.2/payload.js.map +1 -0
- package/package.json +1 -1
- package/src/_runtime/freshness.ts +4 -2
- package/src/_shared/components.ts +388 -24
- package/src/device/list/0.1/payload.ts +4 -2
- package/src/device/list/0.2/payload.ts +4 -2
- package/src/device/register/0.1/payload.ts +4 -2
- package/src/device/register/0.2/payload.ts +4 -2
- package/src/index.ts +31 -0
- package/src/rooms/_shared/0.1/room.ts +1 -1
- package/src/rooms/create/0.2/payload.ts +364 -0
- package/src/rooms/epoch/chain/0.2/payload.ts +347 -0
- package/src/rooms/epoch/prune/0.2/payload.ts +315 -0
- package/src/rooms/info/0.2/payload.ts +700 -0
- package/src/rooms/keys/backfill/0.2/payload.ts +260 -0
- package/src/rooms/keys/browse/0.1/payload.ts +2 -2
- package/src/rooms/keys/browse/0.2/payload.ts +628 -0
- package/src/rooms/keys/chain/0.2/payload.ts +308 -0
- package/src/rooms/keys/profile/read/0.1/payload.ts +2 -2
- package/src/rooms/keys/read/0.1/payload.ts +2 -2
- package/src/rooms/owner/anchor/0.1/payload.ts +2 -2
- package/src/rooms/records/get/0.1/payload.ts +2 -2
- package/src/rooms/records/get/0.2/payload.ts +2 -2
- package/src/rooms/records/list/0.1/payload.ts +2 -2
- package/src/rooms/records/list/0.2/payload.ts +2 -2
- package/src/rooms/records/list/0.3/payload.ts +601 -0
- package/src/rooms/records/prune/0.1/payload.ts +451 -0
- package/src/rooms/records/put/0.3/payload.ts +741 -0
- package/src/rooms/records/retention/set/0.1/payload.ts +338 -0
- package/src/vault/credentials/present/0.1/payload.ts +283 -0
- package/src/voting/_shared/0.1/voting.ts +1 -1
- package/src/voting/board/read/0.1/payload.ts +38 -2
- package/src/voting/trustees/authorize/0.1/payload.ts +434 -0
- package/src/voting/trustees/status/0.1/payload.ts +58 -2
- package/src/vta/pcs/trustee/deal/0.2/payload.ts +1148 -0
- package/src/vta/pcs/trustee/decrypt/0.2/payload.ts +500 -0
- package/src/vta/pcs/trustee/justify/0.2/payload.ts +1167 -0
- package/src/vta/pcs/trustee/keys/0.2/payload.ts +1194 -0
- package/src/vta/pcs/vote-encrypted/0.2/payload.ts +1369 -0
- package/src/vta/webvh/dids/create/1.2/payload.ts +660 -0
- package/src/vtc/_shared/0.1/room-migration.ts +17 -0
- package/src/vtc/_shared/0.1/room-storage.ts +1 -1
- package/src/vtc/_shared/0.2/room-storage.ts +17 -0
- package/src/vtc/admin/events/_shared/0.4/topic.ts +32 -0
- package/src/vtc/admin/events/event/0.4/payload.ts +137 -0
- package/src/vtc/admin/events/subscribe/0.4/payload.ts +318 -0
- package/src/vtc/elections/show/0.1/payload.ts +46 -2
- package/src/vtc/rooms/get/0.2/payload.ts +1372 -0
- package/src/vtc/rooms/storage/migrate/0.2/payload.ts +408 -0
- package/src/vtc/storage/configs/create/0.1/payload.ts +1 -1
- package/src/vtc/storage/configs/create/0.2/payload.ts +830 -0
- package/src/vtc/storage/configs/get/0.1/payload.ts +1 -1
- package/src/vtc/storage/configs/get/0.2/payload.ts +1110 -0
- package/src/vtc/storage/configs/list/0.1/payload.ts +1 -1
- package/src/vtc/storage/configs/list/0.2/payload.ts +1177 -0
- package/src/vtc/storage/configs/update/0.1/payload.ts +1 -1
- package/src/vtc/storage/configs/update/0.2/payload.ts +829 -0
- package/src/vtc/storage/credentials/set/0.1/payload.ts +1 -1
- package/src/vtc/storage/credentials/set/0.2/payload.ts +619 -0
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Source: specs/voting/board/read/0.1/payload.schema.json
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key_VotingV0_1 as Key, LifecycleEntry, Multibase_VotingV0_1 as Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SignedRequest, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, TrusteeStepEntry, UnsealedEntry } from "../../../../_shared/components.js";
|
|
6
|
+
import type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionAuthorizedEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key_VotingV0_1 as Key, LifecycleEntry, Multibase_VotingV0_1 as Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SignedRequest, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, TrusteeStepEntry, UnsealedEntry } from "../../../../_shared/components.js";
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
/**
|
|
@@ -51,7 +51,7 @@ export interface VotingBoardReadResponsePayload {
|
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
54
|
-
export type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key, LifecycleEntry, Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SignedRequest, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, TrusteeStepEntry, UnsealedEntry };
|
|
54
|
+
export type { Answer, Ballot, BoardEntry, BoardHead, Cast, CastEntry, ConfirmationEntry, Dealing, DealingEntry, DecryptionAuthorizedEntry, DecryptionTarget, DigestMultibase, ElectionId, ElectionKey, ElectionKeyEntry, ElectionResult, ElGamalCiphertext, EncryptedCast, EncryptedCastEntry, Ext, GroupElement, GroupScalar, JustificationEntry, Key, LifecycleEntry, Multibase, PartialDecryption, PartialDecryptionsEntry, QuestionResult, ReplacementEntry, ResultEntry, SealedPayload, SealedShare, SigmaProof, SignedRequest, SpoiledEntry, TransportKey, TransportKeyEntry, TrusteeIndex, TrusteeStepEntry, UnsealedEntry };
|
|
55
55
|
|
|
56
56
|
/** Trust Task type URI. */
|
|
57
57
|
export const TYPE_URI = "https://trusttasks.org/spec/voting/board/read/0.1" as const;
|
|
@@ -470,6 +470,24 @@ export const PAYLOAD_SCHEMA = {
|
|
|
470
470
|
"$ref": "#/$defs/SignedRequest"
|
|
471
471
|
}
|
|
472
472
|
}
|
|
473
|
+
},
|
|
474
|
+
{
|
|
475
|
+
"title": "DecryptionAuthorizedEntry",
|
|
476
|
+
"description": "The community's voting/trustees/authorize request, exactly as the ballot box received it: the decryption targets of a closed election, pinned by digest to a head of the board (CONVENTIONS §9.7).",
|
|
477
|
+
"type": "object",
|
|
478
|
+
"additionalProperties": false,
|
|
479
|
+
"required": [
|
|
480
|
+
"kind",
|
|
481
|
+
"request"
|
|
482
|
+
],
|
|
483
|
+
"properties": {
|
|
484
|
+
"kind": {
|
|
485
|
+
"const": "decryptionAuthorized"
|
|
486
|
+
},
|
|
487
|
+
"request": {
|
|
488
|
+
"$ref": "#/$defs/SignedRequest"
|
|
489
|
+
}
|
|
490
|
+
}
|
|
473
491
|
}
|
|
474
492
|
]
|
|
475
493
|
},
|
|
@@ -1480,6 +1498,24 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
|
1480
1498
|
"$ref": "#/$defs/SignedRequest"
|
|
1481
1499
|
}
|
|
1482
1500
|
}
|
|
1501
|
+
},
|
|
1502
|
+
{
|
|
1503
|
+
"title": "DecryptionAuthorizedEntry",
|
|
1504
|
+
"description": "The community's voting/trustees/authorize request, exactly as the ballot box received it: the decryption targets of a closed election, pinned by digest to a head of the board (CONVENTIONS §9.7).",
|
|
1505
|
+
"type": "object",
|
|
1506
|
+
"additionalProperties": false,
|
|
1507
|
+
"required": [
|
|
1508
|
+
"kind",
|
|
1509
|
+
"request"
|
|
1510
|
+
],
|
|
1511
|
+
"properties": {
|
|
1512
|
+
"kind": {
|
|
1513
|
+
"const": "decryptionAuthorized"
|
|
1514
|
+
},
|
|
1515
|
+
"request": {
|
|
1516
|
+
"$ref": "#/$defs/SignedRequest"
|
|
1517
|
+
}
|
|
1518
|
+
}
|
|
1483
1519
|
}
|
|
1484
1520
|
]
|
|
1485
1521
|
},
|
|
@@ -0,0 +1,434 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/voting/trustees/authorize/0.1/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import type { BoardHead, DigestMultibase, ElectionId, ElectionState, ElectionSummary, Ext, TrusteePhase } from "../../../../_shared/components.js";
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* After voting closes, the community authorizes the decryption of exactly the targets it computed from the board: a digest of them, and the head they were computed under.
|
|
11
|
+
*/
|
|
12
|
+
export interface VotingTrusteesAuthorizePayload {
|
|
13
|
+
/**
|
|
14
|
+
* The community's DID: the registrar that registered the election.
|
|
15
|
+
*/
|
|
16
|
+
community: string;
|
|
17
|
+
electionId: ElectionId;
|
|
18
|
+
manifestDigest: DigestMultibase;
|
|
19
|
+
/**
|
|
20
|
+
* The head the targets were computed under: the board through its `closed` or `closedEarly` entry.
|
|
21
|
+
*/
|
|
22
|
+
head: BoardHead;
|
|
23
|
+
/**
|
|
24
|
+
* The `at` of the board's `closed` or `closedEarly` entry.
|
|
25
|
+
*/
|
|
26
|
+
closedAt: string;
|
|
27
|
+
targetCount: number;
|
|
28
|
+
/**
|
|
29
|
+
* SHA-256 over the JCS of the array of DecryptionTarget the community computed, in the order of CONVENTIONS §9.7, as a multihash.
|
|
30
|
+
*/
|
|
31
|
+
targetsDigest: DigestMultibase;
|
|
32
|
+
ext?: Ext;
|
|
33
|
+
}
|
|
34
|
+
export interface VotingTrusteesAuthorizeResponsePayload {
|
|
35
|
+
election: ElectionSummary;
|
|
36
|
+
phase: TrusteePhase;
|
|
37
|
+
ext?: Ext;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
41
|
+
export type { BoardHead, DigestMultibase, ElectionId, ElectionState, ElectionSummary, Ext, TrusteePhase };
|
|
42
|
+
|
|
43
|
+
/** Trust Task type URI. */
|
|
44
|
+
export const TYPE_URI = "https://trusttasks.org/spec/voting/trustees/authorize/0.1" as const;
|
|
45
|
+
|
|
46
|
+
/** Stable alias for this specification's request payload shape. */
|
|
47
|
+
export type Payload = VotingTrusteesAuthorizePayload;
|
|
48
|
+
|
|
49
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
50
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/voting/trustees/authorize/0.1#response" as const;
|
|
51
|
+
|
|
52
|
+
/** Stable alias for this specification's success-response payload shape. */
|
|
53
|
+
export type Response = VotingTrusteesAuthorizeResponsePayload;
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* This specification's payload schema, as a value.
|
|
57
|
+
*
|
|
58
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
59
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
60
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
61
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
62
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
63
|
+
*/
|
|
64
|
+
export const PAYLOAD_SCHEMA = {
|
|
65
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
66
|
+
"$id": "https://trusttasks.org/spec/voting/trustees/authorize/0.1",
|
|
67
|
+
"title": "Voting — Trustees — Authorize — payload",
|
|
68
|
+
"description": "After voting closes, the community authorizes the decryption of exactly the targets it computed from the board: a digest of them, and the head they were computed under.",
|
|
69
|
+
"type": "object",
|
|
70
|
+
"additionalProperties": false,
|
|
71
|
+
"required": [
|
|
72
|
+
"community",
|
|
73
|
+
"electionId",
|
|
74
|
+
"manifestDigest",
|
|
75
|
+
"head",
|
|
76
|
+
"closedAt",
|
|
77
|
+
"targetCount",
|
|
78
|
+
"targetsDigest"
|
|
79
|
+
],
|
|
80
|
+
"properties": {
|
|
81
|
+
"community": {
|
|
82
|
+
"type": "string",
|
|
83
|
+
"minLength": 1,
|
|
84
|
+
"maxLength": 2048,
|
|
85
|
+
"description": "The community's DID: the registrar that registered the election."
|
|
86
|
+
},
|
|
87
|
+
"electionId": {
|
|
88
|
+
"$ref": "#/$defs/ElectionId"
|
|
89
|
+
},
|
|
90
|
+
"manifestDigest": {
|
|
91
|
+
"$ref": "#/$defs/DigestMultibase"
|
|
92
|
+
},
|
|
93
|
+
"head": {
|
|
94
|
+
"$ref": "#/$defs/BoardHead",
|
|
95
|
+
"description": "The head the targets were computed under: the board through its `closed` or `closedEarly` entry."
|
|
96
|
+
},
|
|
97
|
+
"closedAt": {
|
|
98
|
+
"type": "string",
|
|
99
|
+
"format": "date-time",
|
|
100
|
+
"description": "The `at` of the board's `closed` or `closedEarly` entry."
|
|
101
|
+
},
|
|
102
|
+
"targetCount": {
|
|
103
|
+
"type": "integer",
|
|
104
|
+
"minimum": 0,
|
|
105
|
+
"maximum": 100000
|
|
106
|
+
},
|
|
107
|
+
"targetsDigest": {
|
|
108
|
+
"$ref": "#/$defs/DigestMultibase",
|
|
109
|
+
"description": "SHA-256 over the JCS of the array of DecryptionTarget the community computed, in the order of CONVENTIONS §9.7, as a multihash."
|
|
110
|
+
},
|
|
111
|
+
"ext": {
|
|
112
|
+
"$ref": "#/$defs/Ext"
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
"$defs": {
|
|
116
|
+
"Response": {
|
|
117
|
+
"$anchor": "response",
|
|
118
|
+
"title": "Voting — Trustees — Authorize — response payload",
|
|
119
|
+
"type": "object",
|
|
120
|
+
"additionalProperties": false,
|
|
121
|
+
"required": [
|
|
122
|
+
"election",
|
|
123
|
+
"phase"
|
|
124
|
+
],
|
|
125
|
+
"properties": {
|
|
126
|
+
"election": {
|
|
127
|
+
"$ref": "#/$defs/ElectionSummary"
|
|
128
|
+
},
|
|
129
|
+
"phase": {
|
|
130
|
+
"$ref": "#/$defs/TrusteePhase"
|
|
131
|
+
},
|
|
132
|
+
"ext": {
|
|
133
|
+
"$ref": "#/$defs/Ext"
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
"Ext": {
|
|
138
|
+
"title": "Ext",
|
|
139
|
+
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|
|
140
|
+
"type": "object",
|
|
141
|
+
"minProperties": 1,
|
|
142
|
+
"additionalProperties": true,
|
|
143
|
+
"propertyNames": {
|
|
144
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"TrusteePhase": {
|
|
148
|
+
"title": "TrusteePhase",
|
|
149
|
+
"description": "`enrolling`: transport keys are being published. `dealing`: dealings are. `confirming`: each trustee confirms or complains. `keyed`: the election key is formed. `decrypting`: voting has closed and partial decryptions are being published. `done`: every target is decrypted. `failed`: the key could not be formed in time.",
|
|
150
|
+
"type": "string",
|
|
151
|
+
"enum": [
|
|
152
|
+
"enrolling",
|
|
153
|
+
"dealing",
|
|
154
|
+
"confirming",
|
|
155
|
+
"keyed",
|
|
156
|
+
"decrypting",
|
|
157
|
+
"done",
|
|
158
|
+
"failed"
|
|
159
|
+
]
|
|
160
|
+
},
|
|
161
|
+
"ElectionSummary": {
|
|
162
|
+
"title": "ElectionSummary",
|
|
163
|
+
"description": "A ballot box's view of one election.",
|
|
164
|
+
"type": "object",
|
|
165
|
+
"additionalProperties": false,
|
|
166
|
+
"required": [
|
|
167
|
+
"electionId",
|
|
168
|
+
"community",
|
|
169
|
+
"manifestDigest",
|
|
170
|
+
"state",
|
|
171
|
+
"ballotsAdmitted",
|
|
172
|
+
"head"
|
|
173
|
+
],
|
|
174
|
+
"properties": {
|
|
175
|
+
"electionId": {
|
|
176
|
+
"$ref": "#/$defs/ElectionId"
|
|
177
|
+
},
|
|
178
|
+
"community": {
|
|
179
|
+
"type": "string",
|
|
180
|
+
"minLength": 1,
|
|
181
|
+
"maxLength": 2048
|
|
182
|
+
},
|
|
183
|
+
"manifestDigest": {
|
|
184
|
+
"$ref": "#/$defs/DigestMultibase"
|
|
185
|
+
},
|
|
186
|
+
"state": {
|
|
187
|
+
"$ref": "#/$defs/ElectionState"
|
|
188
|
+
},
|
|
189
|
+
"ballotsAdmitted": {
|
|
190
|
+
"type": "integer",
|
|
191
|
+
"minimum": 0,
|
|
192
|
+
"description": "Distinct tags with a counted ballot."
|
|
193
|
+
},
|
|
194
|
+
"head": {
|
|
195
|
+
"$ref": "#/$defs/BoardHead"
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
},
|
|
199
|
+
"BoardHead": {
|
|
200
|
+
"title": "BoardHead",
|
|
201
|
+
"description": "A board's tree head (RFC 9162 §2.1). A head is signed by being carried in a document the ballot box signs; whoever keeps a head keeps that whole document.",
|
|
202
|
+
"type": "object",
|
|
203
|
+
"additionalProperties": false,
|
|
204
|
+
"required": [
|
|
205
|
+
"electionId",
|
|
206
|
+
"treeSize",
|
|
207
|
+
"rootHash",
|
|
208
|
+
"issuedAt"
|
|
209
|
+
],
|
|
210
|
+
"properties": {
|
|
211
|
+
"electionId": {
|
|
212
|
+
"$ref": "#/$defs/ElectionId"
|
|
213
|
+
},
|
|
214
|
+
"treeSize": {
|
|
215
|
+
"type": "integer",
|
|
216
|
+
"minimum": 0
|
|
217
|
+
},
|
|
218
|
+
"rootHash": {
|
|
219
|
+
"$ref": "#/$defs/DigestMultibase",
|
|
220
|
+
"description": "The RFC 9162 Merkle tree hash (SHA-256) of the first `treeSize` entries, as a multihash."
|
|
221
|
+
},
|
|
222
|
+
"issuedAt": {
|
|
223
|
+
"type": "string",
|
|
224
|
+
"format": "date-time"
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
},
|
|
228
|
+
"ElectionId": {
|
|
229
|
+
"title": "ElectionId",
|
|
230
|
+
"description": "An election's identifier, unique within its community. A closed alphabet: it appears in the ticket class label `voter/<electionId>` and is framed into every hash a cast is bound to.",
|
|
231
|
+
"type": "string",
|
|
232
|
+
"pattern": "^[A-Za-z0-9._-]{1,128}$"
|
|
233
|
+
},
|
|
234
|
+
"DigestMultibase": {
|
|
235
|
+
"title": "DigestMultibase",
|
|
236
|
+
"description": "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.",
|
|
237
|
+
"type": "string",
|
|
238
|
+
"minLength": 16,
|
|
239
|
+
"pattern": "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$",
|
|
240
|
+
"examples": [
|
|
241
|
+
"zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"
|
|
242
|
+
]
|
|
243
|
+
},
|
|
244
|
+
"ElectionState": {
|
|
245
|
+
"title": "ElectionState",
|
|
246
|
+
"type": "string",
|
|
247
|
+
"enum": [
|
|
248
|
+
"registered",
|
|
249
|
+
"registration",
|
|
250
|
+
"voting",
|
|
251
|
+
"closed",
|
|
252
|
+
"tallied",
|
|
253
|
+
"cancelled"
|
|
254
|
+
]
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
} as const;
|
|
258
|
+
|
|
259
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
260
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
261
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
262
|
+
"$ref": "#/$defs/Response",
|
|
263
|
+
"$defs": {
|
|
264
|
+
"Response": {
|
|
265
|
+
"$anchor": "response",
|
|
266
|
+
"title": "Voting — Trustees — Authorize — response payload",
|
|
267
|
+
"type": "object",
|
|
268
|
+
"additionalProperties": false,
|
|
269
|
+
"required": [
|
|
270
|
+
"election",
|
|
271
|
+
"phase"
|
|
272
|
+
],
|
|
273
|
+
"properties": {
|
|
274
|
+
"election": {
|
|
275
|
+
"$ref": "#/$defs/ElectionSummary"
|
|
276
|
+
},
|
|
277
|
+
"phase": {
|
|
278
|
+
"$ref": "#/$defs/TrusteePhase"
|
|
279
|
+
},
|
|
280
|
+
"ext": {
|
|
281
|
+
"$ref": "#/$defs/Ext"
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
},
|
|
285
|
+
"Ext": {
|
|
286
|
+
"title": "Ext",
|
|
287
|
+
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|
|
288
|
+
"type": "object",
|
|
289
|
+
"minProperties": 1,
|
|
290
|
+
"additionalProperties": true,
|
|
291
|
+
"propertyNames": {
|
|
292
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
"TrusteePhase": {
|
|
296
|
+
"title": "TrusteePhase",
|
|
297
|
+
"description": "`enrolling`: transport keys are being published. `dealing`: dealings are. `confirming`: each trustee confirms or complains. `keyed`: the election key is formed. `decrypting`: voting has closed and partial decryptions are being published. `done`: every target is decrypted. `failed`: the key could not be formed in time.",
|
|
298
|
+
"type": "string",
|
|
299
|
+
"enum": [
|
|
300
|
+
"enrolling",
|
|
301
|
+
"dealing",
|
|
302
|
+
"confirming",
|
|
303
|
+
"keyed",
|
|
304
|
+
"decrypting",
|
|
305
|
+
"done",
|
|
306
|
+
"failed"
|
|
307
|
+
]
|
|
308
|
+
},
|
|
309
|
+
"ElectionSummary": {
|
|
310
|
+
"title": "ElectionSummary",
|
|
311
|
+
"description": "A ballot box's view of one election.",
|
|
312
|
+
"type": "object",
|
|
313
|
+
"additionalProperties": false,
|
|
314
|
+
"required": [
|
|
315
|
+
"electionId",
|
|
316
|
+
"community",
|
|
317
|
+
"manifestDigest",
|
|
318
|
+
"state",
|
|
319
|
+
"ballotsAdmitted",
|
|
320
|
+
"head"
|
|
321
|
+
],
|
|
322
|
+
"properties": {
|
|
323
|
+
"electionId": {
|
|
324
|
+
"$ref": "#/$defs/ElectionId"
|
|
325
|
+
},
|
|
326
|
+
"community": {
|
|
327
|
+
"type": "string",
|
|
328
|
+
"minLength": 1,
|
|
329
|
+
"maxLength": 2048
|
|
330
|
+
},
|
|
331
|
+
"manifestDigest": {
|
|
332
|
+
"$ref": "#/$defs/DigestMultibase"
|
|
333
|
+
},
|
|
334
|
+
"state": {
|
|
335
|
+
"$ref": "#/$defs/ElectionState"
|
|
336
|
+
},
|
|
337
|
+
"ballotsAdmitted": {
|
|
338
|
+
"type": "integer",
|
|
339
|
+
"minimum": 0,
|
|
340
|
+
"description": "Distinct tags with a counted ballot."
|
|
341
|
+
},
|
|
342
|
+
"head": {
|
|
343
|
+
"$ref": "#/$defs/BoardHead"
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
},
|
|
347
|
+
"BoardHead": {
|
|
348
|
+
"title": "BoardHead",
|
|
349
|
+
"description": "A board's tree head (RFC 9162 §2.1). A head is signed by being carried in a document the ballot box signs; whoever keeps a head keeps that whole document.",
|
|
350
|
+
"type": "object",
|
|
351
|
+
"additionalProperties": false,
|
|
352
|
+
"required": [
|
|
353
|
+
"electionId",
|
|
354
|
+
"treeSize",
|
|
355
|
+
"rootHash",
|
|
356
|
+
"issuedAt"
|
|
357
|
+
],
|
|
358
|
+
"properties": {
|
|
359
|
+
"electionId": {
|
|
360
|
+
"$ref": "#/$defs/ElectionId"
|
|
361
|
+
},
|
|
362
|
+
"treeSize": {
|
|
363
|
+
"type": "integer",
|
|
364
|
+
"minimum": 0
|
|
365
|
+
},
|
|
366
|
+
"rootHash": {
|
|
367
|
+
"$ref": "#/$defs/DigestMultibase",
|
|
368
|
+
"description": "The RFC 9162 Merkle tree hash (SHA-256) of the first `treeSize` entries, as a multihash."
|
|
369
|
+
},
|
|
370
|
+
"issuedAt": {
|
|
371
|
+
"type": "string",
|
|
372
|
+
"format": "date-time"
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
},
|
|
376
|
+
"ElectionId": {
|
|
377
|
+
"title": "ElectionId",
|
|
378
|
+
"description": "An election's identifier, unique within its community. A closed alphabet: it appears in the ticket class label `voter/<electionId>` and is framed into every hash a cast is bound to.",
|
|
379
|
+
"type": "string",
|
|
380
|
+
"pattern": "^[A-Za-z0-9._-]{1,128}$"
|
|
381
|
+
},
|
|
382
|
+
"DigestMultibase": {
|
|
383
|
+
"title": "DigestMultibase",
|
|
384
|
+
"description": "A cryptographic digest as a multibase-encoded multihash — the encoding the W3C Verifiable Credentials Data Model 2.0 defines for `digestMultibase`, and the one `did:webvh` uses for its SCID and entry hashes.\n\nMultihash carries the hash algorithm in-band, so the value is self-describing and the wire format survives an algorithm change without a schema revision; multibase does the same for the base encoding, so a verifier never infers base58 from base64url by context. A bare hex string or a `sha-256:`-style prefix hard-codes one algorithm into the wire contract and is non-conforming here.\n\nThis definition constrains the *encoding only*. What the digest is computed over is stated by each referencing field, because it differs legitimately: a digest over a JSON document is taken over its RFC 8785 (JCS) canonicalization, while a digest over an opaque artifact is taken over its bytes. A field whose input is a JSON document and which does not name a canonicalization is not reproducible.\n\nRestricted to the two multibase headers W3C Controlled Identifiers 1.0 §2.4 normatively requires — `z` (base58btc) and `u` (base64url-no-pad). CID permits others but states that \"interoperability is not guaranteed between implementations using such values\", and a registry whose purpose is interoperability should not mint digests a conforming verifier may be unable to read. The alphabets are enforced rather than assumed: base58btc excludes 0, O, I and l, and an earlier permissive pattern let three published examples carry digests that were not valid base58 at all. base58btc is RECOMMENDED, for consistency with `did:key` and `did:webvh`.",
|
|
385
|
+
"type": "string",
|
|
386
|
+
"minLength": 16,
|
|
387
|
+
"pattern": "^(z[1-9A-HJ-NP-Za-km-z]+|u[A-Za-z0-9_-]+)$",
|
|
388
|
+
"examples": [
|
|
389
|
+
"zQmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR"
|
|
390
|
+
]
|
|
391
|
+
},
|
|
392
|
+
"ElectionState": {
|
|
393
|
+
"title": "ElectionState",
|
|
394
|
+
"type": "string",
|
|
395
|
+
"enum": [
|
|
396
|
+
"registered",
|
|
397
|
+
"registration",
|
|
398
|
+
"voting",
|
|
399
|
+
"closed",
|
|
400
|
+
"tallied",
|
|
401
|
+
"cancelled"
|
|
402
|
+
]
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
} as const;
|
|
406
|
+
|
|
407
|
+
/**
|
|
408
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
409
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
410
|
+
* per-specification and cannot be derived from the document alone, and
|
|
411
|
+
* item 2 needs the schema this carries.
|
|
412
|
+
*/
|
|
413
|
+
export const SPEC = {
|
|
414
|
+
typeUri: TYPE_URI,
|
|
415
|
+
isBearer: false,
|
|
416
|
+
isProofRequired: true,
|
|
417
|
+
isRecipientRequired: true,
|
|
418
|
+
isIssuedAtRequired: true,
|
|
419
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
420
|
+
} as const;
|
|
421
|
+
|
|
422
|
+
/**
|
|
423
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
424
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
425
|
+
* parties (§7.3 item 5).
|
|
426
|
+
*/
|
|
427
|
+
export const RESPONSE_SPEC = {
|
|
428
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
429
|
+
isBearer: false,
|
|
430
|
+
isProofRequired: true,
|
|
431
|
+
isRecipientRequired: true,
|
|
432
|
+
isIssuedAtRequired: true,
|
|
433
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
434
|
+
} as const;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Source: specs/voting/trustees/status/0.1/payload.schema.json
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import type { Dealing, DecryptionTarget, ElectionId, ElectionKey, ElGamalCiphertext, Ext, GroupElement, GroupScalar, SealedPayload, SealedShare, SigmaProof, TransportKey, TrusteeIndex, TrusteePhase } from "../../../../_shared/components.js";
|
|
6
|
+
import type { Dealing, DecryptionTarget, ElectionId, ElectionKey, ElGamalCiphertext, Ext, GroupElement, GroupScalar, SealedPayload, SealedShare, SigmaProof, SignedRequest, TransportKey, TrusteeCeremony, TrusteeIndex, TrusteePhase } from "../../../../_shared/components.js";
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
/**
|
|
@@ -55,10 +55,18 @@ export interface VotingTrusteesStatusResponsePayload {
|
|
|
55
55
|
*/
|
|
56
56
|
decrypted: TrusteeIndex[];
|
|
57
57
|
ext?: Ext;
|
|
58
|
+
/**
|
|
59
|
+
* Every trusteeStep request on the board, in board order, as received. What a trustee's VTA acts on: the other members of this answer carry no trustee's proof.
|
|
60
|
+
*/
|
|
61
|
+
steps?: TrusteeCeremony;
|
|
62
|
+
/**
|
|
63
|
+
* Once the community has authorized decryption: its voting/trustees/authorize request, as received. A trustee's VTA decrypts only the targets it pins.
|
|
64
|
+
*/
|
|
65
|
+
authorization?: SignedRequest;
|
|
58
66
|
}
|
|
59
67
|
|
|
60
68
|
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
61
|
-
export type { Dealing, DecryptionTarget, ElectionId, ElectionKey, ElGamalCiphertext, Ext, GroupElement, GroupScalar, SealedPayload, SealedShare, SigmaProof, TransportKey, TrusteeIndex, TrusteePhase };
|
|
69
|
+
export type { Dealing, DecryptionTarget, ElectionId, ElectionKey, ElGamalCiphertext, Ext, GroupElement, GroupScalar, SealedPayload, SealedShare, SigmaProof, SignedRequest, TransportKey, TrusteeCeremony, TrusteeIndex, TrusteePhase };
|
|
62
70
|
|
|
63
71
|
/** Trust Task type URI. */
|
|
64
72
|
export const TYPE_URI = "https://trusttasks.org/spec/voting/trustees/status/0.1" as const;
|
|
@@ -200,9 +208,33 @@ export const PAYLOAD_SCHEMA = {
|
|
|
200
208
|
},
|
|
201
209
|
"ext": {
|
|
202
210
|
"$ref": "#/$defs/Ext"
|
|
211
|
+
},
|
|
212
|
+
"steps": {
|
|
213
|
+
"$ref": "#/$defs/TrusteeCeremony",
|
|
214
|
+
"description": "Every trusteeStep request on the board, in board order, as received. What a trustee's VTA acts on: the other members of this answer carry no trustee's proof."
|
|
215
|
+
},
|
|
216
|
+
"authorization": {
|
|
217
|
+
"$ref": "#/$defs/SignedRequest",
|
|
218
|
+
"description": "Once the community has authorized decryption: its voting/trustees/authorize request, as received. A trustee's VTA decrypts only the targets it pins."
|
|
203
219
|
}
|
|
204
220
|
}
|
|
205
221
|
},
|
|
222
|
+
"SignedRequest": {
|
|
223
|
+
"title": "SignedRequest",
|
|
224
|
+
"description": "A whole Trust Task request document — `id`, `type`, `issuer`, `payload` and every other member, `proof` included — exactly as the ballot box received it, never re-serialised: its proof is taken over its members, and a re-serialised copy does not reliably reproduce them. Typed as an open object so every member survives; CONVENTIONS §9.6 gives the checks that make it a trustee's step.",
|
|
225
|
+
"type": "object",
|
|
226
|
+
"minProperties": 1
|
|
227
|
+
},
|
|
228
|
+
"TrusteeCeremony": {
|
|
229
|
+
"title": "TrusteeCeremony",
|
|
230
|
+
"description": "The trustees' ceremony as the board holds it: the `request` of every `trusteeStep` entry, in board order, each exactly as the ballot box received it (CONVENTIONS §9.6). Whoever acts on it verifies each step as its trustee's before taking it; nothing in it is believed for having been passed along.",
|
|
231
|
+
"type": "array",
|
|
232
|
+
"minItems": 1,
|
|
233
|
+
"maxItems": 4224,
|
|
234
|
+
"items": {
|
|
235
|
+
"$ref": "#/$defs/SignedRequest"
|
|
236
|
+
}
|
|
237
|
+
},
|
|
206
238
|
"Ext": {
|
|
207
239
|
"title": "Ext",
|
|
208
240
|
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|
|
@@ -579,9 +611,33 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
|
579
611
|
},
|
|
580
612
|
"ext": {
|
|
581
613
|
"$ref": "#/$defs/Ext"
|
|
614
|
+
},
|
|
615
|
+
"steps": {
|
|
616
|
+
"$ref": "#/$defs/TrusteeCeremony",
|
|
617
|
+
"description": "Every trusteeStep request on the board, in board order, as received. What a trustee's VTA acts on: the other members of this answer carry no trustee's proof."
|
|
618
|
+
},
|
|
619
|
+
"authorization": {
|
|
620
|
+
"$ref": "#/$defs/SignedRequest",
|
|
621
|
+
"description": "Once the community has authorized decryption: its voting/trustees/authorize request, as received. A trustee's VTA decrypts only the targets it pins."
|
|
582
622
|
}
|
|
583
623
|
}
|
|
584
624
|
},
|
|
625
|
+
"SignedRequest": {
|
|
626
|
+
"title": "SignedRequest",
|
|
627
|
+
"description": "A whole Trust Task request document — `id`, `type`, `issuer`, `payload` and every other member, `proof` included — exactly as the ballot box received it, never re-serialised: its proof is taken over its members, and a re-serialised copy does not reliably reproduce them. Typed as an open object so every member survives; CONVENTIONS §9.6 gives the checks that make it a trustee's step.",
|
|
628
|
+
"type": "object",
|
|
629
|
+
"minProperties": 1
|
|
630
|
+
},
|
|
631
|
+
"TrusteeCeremony": {
|
|
632
|
+
"title": "TrusteeCeremony",
|
|
633
|
+
"description": "The trustees' ceremony as the board holds it: the `request` of every `trusteeStep` entry, in board order, each exactly as the ballot box received it (CONVENTIONS §9.6). Whoever acts on it verifies each step as its trustee's before taking it; nothing in it is believed for having been passed along.",
|
|
634
|
+
"type": "array",
|
|
635
|
+
"minItems": 1,
|
|
636
|
+
"maxItems": 4224,
|
|
637
|
+
"items": {
|
|
638
|
+
"$ref": "#/$defs/SignedRequest"
|
|
639
|
+
}
|
|
640
|
+
},
|
|
585
641
|
"Ext": {
|
|
586
642
|
"title": "Ext",
|
|
587
643
|
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|