Skip to content

Root package

Use the root package for the supported voting workflow. Advanced cryptographic and transcript primitives also have public subpath entrypoints such as threshold-elgamal/proofs, threshold-elgamal/threshold, threshold-elgamal/dkg, threshold-elgamal/vss, threshold-elgamal/elgamal, threshold-elgamal/protocol, and threshold-elgamal/core.

  • manifest helpers
  • roster hashing and session derivation
  • transport and authentication helpers
  • public builders for the standard ceremony payloads
  • full public-board verification
  • full ceremony verification
  • manifest and session setup: createElectionManifest, hashRosterEntries, hashElectionManifest, deriveSessionId
  • browser-side key material: generateAuthKeyPair, exportAuthPublicKey, generateTransportKeyPair, exportTransportPublicKey
  • encrypted share transport: encryptEnvelope, decryptEnvelope
  • public board verification: tryVerifyElectionCeremony, verifyElectionCeremony
  • published payload construction: createManifestPublicationPayload, createRegistrationPayload, createManifestAcceptancePayload, createBallotSubmissionPayload, createBallotClosePayload, createDecryptionSharePayload, createTallyPublicationPayload
  • advanced reveal primitives: prepareAggregateForDecryption and combineDecryptionShares from threshold-elgamal/threshold, plus createDLEQProof from threshold-elgamal/proofs
import {
createElectionManifest,
createManifestPublicationPayload,
createRegistrationPayload,
createManifestAcceptancePayload,
createBallotClosePayload,
createDecryptionSharePayload,
verifyElectionCeremony,
} from "threshold-elgamal";
  • you want the ristretto255 voting workflow
  • you want the minimal manifest and derived majority-threshold rules
  • you want the workflow-facing builders and verifiers without importing the lower-level proof, threshold, DKG, or VSS modules directly
  • you need direct proof helpers such as createDLEQProof(...) or createSchnorrProof(...)
  • you need direct threshold helpers such as prepareAggregateForDecryption(...) or combineDecryptionShares(...)
  • you need DKG transcript replay or trustee verification-key derivation
  • you need generic protocol signing, transcript hashing, ballot-proof verification, or protocol payload types
  • you need Feldman or Pedersen commitment/share helpers
  • you need low-level additive ElGamal, explicit error classes, or core arithmetic/constants
  • exact signatures, types, and return shapes for the exported surface
  • contract-level detail for the full ceremony types
  • module-level separation between the workflow root package and the advanced public submodules