Documentation
¶
Overview ¶
Package config provides configuration for circuit artifacts including URLs and hashes for various circuit components used in the Vocdoni system.
Index ¶
Constants ¶
View Source
const ( // DefaultArtifactsBaseURL is the base URL for circuit artifacts storage DefaultArtifactsBaseURL = "https://circuits.ams3.cdn.digitaloceanspaces.com" // DefaultArtifactsRelease is the release version for circuit artifacts DefaultArtifactsRelease = "dev" )
View Source
const ( BallotProofCircuitHash = "e287dbc72dbdb4a938db90b61637a0249b5d4f8c294fbcf55e4f08881883112a" BallotProofProvingKeyHash = "982f1a850bc12325001e0c91d5238ae69b6b7ea20b3d5c1c18319d70a5dd2d65" BallotProofVerificationKeyHash = "1675949c5628cfd347e93cfe5187805d28b5e8cb58591085b58eaa1953371991" VoteVerifierCircuitHash = "fd38d5ba055c8d05f13ae341443d201ac528835c9c1c89be2f9d1590693aa649" VoteVerifierProvingKeyHash = "3d347d6747183a1e4df8149125eefa5636344d738c27a31f3bb0836342cfb22b" VoteVerifierVerificationKeyHash = "5283e7b3a02b33c7ad71e396790b26d1daadf444dc722f0407db4dd8c061d5f0" AggregatorCircuitHash = "c59ac087ecad909832c7893a1afae99f0f34799e9ce2ebaf87fbab469c56f0a4" AggregatorProvingKeyHash = "c4be0a20a208426b67cec4c3924be29c01bafadd3ab01450221a620db5c1af49" AggregatorVerificationKeyHash = "bd268629d93e545cd6e896fe0a22191b90ccad16c1d4270476517177553a26c6" StateTransitionCircuitHash = "eef028df6cdcf4082a1afb8f2aa0044e2cbe9851c9cc2e3c8b6cf058dc6a83c8" StateTransitionProvingKeyHash = "3cf12139517d8f3edca63bfdca30114ed654573b53119d391bb54983db6391dd" StateTransitionVerificationKeyHash = "a03d79f9eaf0600cbb7f282fd07aaab1456d80b6c89103cc551c7e952cd59116" ResultsVerifierCircuitHash = "7da3dc581758815ae050b592d4a25189a44c2ec7e3e122559573a4f953a1e412" ResultsVerifierProvingKeyHash = "b590ba65ecac3aa3c4cc2acdacaa4401c607720beb50c12ea0dd6d23b64e87a0" ResultsVerifierVerificationKeyHash = "9cbb1b36ac8e7ee1fe32a9c7d8c11d47bb7e88672121752e46eb3ff271cabdeb" BallotProofWasmHelperHash = "9ea8f6989eab0c8e848902ee4289d6b6acb076056f0391e483befbe8348bc6c8" BallotProofWasmExecJsHash = "0c949f4996f9a89698e4b5c586de32249c3b69b7baadb64d220073cc04acba14" )
Hashes of each circuit artifacts
Variables ¶
View Source
var ( // BallotProofCircuitURL is the URL for the ballot proof circuit WASM file BallotProofCircuitURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, BallotProofCircuitHash) // BallotProofProvingKeyURL is the URL for the ballot proof proving key BallotProofProvingKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, BallotProofProvingKeyHash) // BallotProofVerificationKeyURL is the URL for the ballot proof verification key BallotProofVerificationKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, BallotProofVerificationKeyHash) // VoteVerifierCircuitURL is the URL for the vote verifier circuit VoteVerifierCircuitURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, VoteVerifierCircuitHash) // VoteVerifierProvingKeyURL is the URL for the vote verifier proving key VoteVerifierProvingKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, VoteVerifierProvingKeyHash) // VoteVerifierVerificationKeyURL is the URL for the vote verifier verification key VoteVerifierVerificationKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, VoteVerifierVerificationKeyHash) // AggregatorCircuitURL is the URL for the aggregator circuit AggregatorCircuitURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, AggregatorCircuitHash) // AggregatorProvingKeyURL is the URL for the aggregator proving key AggregatorProvingKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, AggregatorProvingKeyHash) // AggregatorVerificationKeyURL is the URL for the aggregator verification key AggregatorVerificationKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, AggregatorVerificationKeyHash) // StateTransitionCircuitURL is the URL for the statetransition circuit StateTransitionCircuitURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, StateTransitionCircuitHash) // StateTransitionProvingKeyURL is the URL for the statetransition proving key StateTransitionProvingKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, StateTransitionProvingKeyHash) // StateTransitionVerificationKeyURL is the URL for the statetransition verification key StateTransitionVerificationKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, StateTransitionVerificationKeyHash) // ResultsVerifierCircuitURL is the URL for the statetransition circuit ResultsVerifierCircuitURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, ResultsVerifierCircuitHash) // ResultsVerifierProvingKeyURL is the URL for the resultsverifier proving key ResultsVerifierProvingKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, ResultsVerifierProvingKeyHash) // ResultsVerifierVerificationKeyURL is the URL for the resultsverifier verification key ResultsVerifierVerificationKeyURL = fmt.Sprintf("%s/%s/%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, ResultsVerifierVerificationKeyHash) // BallotProofWasmHelperURL is the default URL for the WASM helper BallotProofWasmHelperURL = fmt.Sprintf("%s/%s/davinci_crypto_%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, BallotProofWasmHelperHash[len(BallotProofWasmHelperHash)-4:]) // BallotProofWasmExecJsURL is the default URL for the WASM exec JS BallotProofWasmExecJsURL = fmt.Sprintf("%s/%s/wasm_exec_%s", DefaultArtifactsBaseURL, DefaultArtifactsRelease, BallotProofWasmExecJsHash[len(BallotProofWasmExecJsHash)-4:]) )
View Source
var KZGTrustedSetup []byte
KZGTrustedSetup contains the embedded KZG trusted setup data
View Source
var TestConfig = DavinciWeb3Config{
ProcessRegistrySmartContract: "0xcf7ed3acca5a467e9e704c703e8d87f634fb0fc9",
ResultsZKVerifier: "0x9fe46736679d2d9a65f0992f2272de9f3c7fa6e0",
StateTransitionZKVerifier: "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512",
}
Functions ¶
This section is empty.
Types ¶
type DavinciWeb3Config ¶
type DavinciWeb3Config struct {
ProcessRegistrySmartContract string
ResultsZKVerifier string
StateTransitionZKVerifier string
}
DavinciWeb3Config contains the smart contract addresses for Davinci.
Click to show internal directories.
Click to hide internal directories.