arnaucube
arnaucube/davinci-paperPublic Self-hosted repository
minor changes
bellesmarta belles.mm@gmail.com
Wed, 18 Mar 2026 11:48:56 +0100
commit

193b1f5c9b86f115a7a1891837134587b83474d0

parent

1fd4c6893db082d8ed4ade55aaf47dbcaf16d72b

M v2/build/main.tex → v2/build/main.tex

@@ -44,7 +44,7 @@ \thispagestyle{plain}

%\addcontentsline{toc}{section}{\protect\numberline{}Abstract} \begin{abstract} - \Davinci is the evolution of the Vocdoni voting protocol, designed to empower civil society by providing essential tools for secure, verifiable, and anonymous digital voting. Using recent advancements in \ac{ZK} proof systems and blockchain technology, \davinci transitions to a specialized \ac{ZK} roll-up system that inherits network security from settlement layers such as the Ethereum mainnet. The system relies on cryptographic proofs to ensure integrity and security, eliminating the need for centralized authorities. By integrating \acsp{ZK-SNARK} and threshold homomorphic encryption, \davinci enables end-to-end verifiability, privacy, and trustlessness in election processes. The protocol employs distributed key generation among sequencers, coordinated through Ethereum smart contracts, and uses Ethereum data blobs for data availability. With a focus on accessibility, scalability, receipt-freeness, and automation, \davinci aims to facilitate high-frequency and low-cost voting, fostering mass adoption of voting and simplifying civil participation. Moreover, the introduction of the Vocdoni token aligns incentives among participants, ensuring the system's sustainability and enabling decentralized governance. + \Davinci is the evolution of the Vocdoni voting protocol, designed to empower civil society by providing essential tools for secure, verifiable, and anonymous digital voting. Using recent advancements in \ac{ZK} proof systems and blockchain technology, \davinci transitions to a specialized \ac{ZK} rollup system that inherits network security from settlement layers such as the Ethereum mainnet. The system relies on cryptographic proofs to ensure integrity and security, eliminating the need for centralized authorities. By integrating \acsp{ZK-SNARK} and threshold homomorphic encryption, \davinci enables end-to-end verifiability, privacy, and trustlessness in election processes. The protocol employs distributed key generation among sequencers, coordinated through Ethereum smart contracts, and uses Ethereum data blobs for data availability. With a focus on accessibility, scalability, receipt-freeness, and automation, \davinci aims to facilitate high-frequency and low-cost voting, fostering mass adoption of voting and simplifying civil participation. Moreover, the introduction of the Vocdoni token aligns incentives among participants, ensuring the system's sustainability and enabling decentralized governance. % Finally, the design of \davinci is grounded in practicality; All components are implemented using current technologies and have undergone proof-of-concept testing. %This ensures that In sum, the proposed architecture is not merely theoretical, but a viable solution ready for short-term deployment. The source code has been made open source, allowing practitioners and researchers to further investigate its details and potential for future uses.

@@ -58,7 +58,6 @@ \begin{itemize}

\item Notation considerations: \begin{itemize} \item From \textit{address} to \textit{nullifier} (if you think of an address as a token that allows voters to vote). - \item From \textit{IPFS} to \textit{bulletin board}. \item From \textit{aggregation or accumulation} (in aggregation circuit) to \textit{batching}. \end{itemize} \item Add a section with vulnerabilities.
M v2/sections/analysis.tex → v2/sections/analysis.tex

@@ -19,7 +19,7 @@ \item \textit{Concealing overwrites}: to prevent observers from distinguishing overwrites from routine re-randomizations, sequencers periodically re-encrypt a random subset of stored ballots. This obfuscation ensures that overwrites remain indistinguishable from normal re-randomizations, strengthening receipt-freeness.

\end{itemize} -\paragraph{Privacy.} Ballots remain secret even though encrypted ballots are publicly stored and processed. Ballot secrecy is preserved through ElGamal encryption, which allows votes to be aggregated without decryption. Encrypted ballots are stored in public repositories (e.g., Ethereum blobs). Because of \ac{DKG} sequencers cannot decrypt individual ballots themselves. {\color{blue}The protocol does not reveal the ballot but it does reveal if someone has voted or not.} +\paragraph{Privacy.} Ballots remain secret even though encrypted ballots are publicly stored and processed. Ballot secrecy is preserved through ElGamal encryption, which allows votes to be aggregated without decryption. Encrypted ballots are stored in public repositories (e.g., Ethereum blobs). Because of \ac{DKG} sequencers cannot decrypt individual ballots themselves. {\color{blue}The protocol does not reveal the ballot but it does reveal if someone has voted or not.} Individual ballots remain private because the protocol only invokes threshold decryption on the final aggregate, not on each ballot separately. \paragraph{Quantum resistance.} Quantum computers threaten discrete-logarithm-based cryptography such as ECDSA and ElGamal. For this reason, \davinci is designed in a modular way that would allow to migrate to post-quantum primitives in the longer term. For example,use CRYSTALS-Dilithium, Falcon, or Rainbow, for signature schemes, Brakerski-Gentry-Vaikuntanathan (BGV) or Brakerski/Fan-Vercauteren (BFV) which are lattice-based homomorphic encryption schemes, and ZK-STARKs for post-quantum zero-knowledge proofs. {\color{blue} Add citations to protocols.}
M v2/sections/background.tex → v2/sections/background.tex

@@ -47,7 +47,7 @@ Informally, while a \ac{ZK} proof convinces the verifier that a valid witness exists, an argument of knowledge additionally ensures that the prover actually knows such a witness, except with negligible probability. \acsp{ZK-SNARK} extend this notion with two crucial properties: they are non-interactive, requiring only a single message from prover to verifier, and succinct, meaning that proof size and verification cost remain small regardless of the size of the underlying statement. For instance, Groth16 proofs~\cite{groth2016size}, which rely on pairing-based cryptography over elliptic curves, %to achieve short proofs and fast verification [Gro16, GWC19].

are only about 200 bytes long and can be verified in a few milliseconds. These properties make \acsp{ZK-SNARK} particularly well-suited for blockchain applications, where verification cost and data size are critical. In \davinci, \acsp{ZK-SNARK} are used at multiple stages of the protocol: voters generate proofs to show that their encrypted ballots are correct and sequencers use recursive \acsp{ZK-SNARK} to allow multiple proofs to be aggregated efficiently and generate proofs to attest to valid state transitions. In essence, \acsp{ZK-SNARK} enable both voters and sequencers to produce compact proofs that can be checked on-chain, ensuring that all protocol rules are followed without requiring trust in any party. \paragraph{Trusted setup.} -A limitation of some \ac{ZK-SNARK} protocols is their reliance on a \ac{CRS} generated during a so-called trusted setup. The \ac{CRS} is built from random values that must not be known to either the prover or the verifier. To achieve this, the \ac{CRS} can be created by a trusted third party or, more robustly, via a secure \ac{MPC} protocol \cite{canetti2001universally}. In an MPC setup, it suffices that at least one participant discards their secret contribution to ensure the integrity of the whole ceremony. {\color{blue}For \davinci, we run an \ac{MPC} for each of the circuits, see Sections~\ref{sec:cryptographic-primitives:zkp} and~\ref{sec:analysis:implementation}.} +A limitation of some \ac{ZK-SNARK} protocols is their reliance on a \ac{CRS} generated during a so-called trusted setup. The \ac{CRS} is built from random values that must not be known to either the prover or the verifier. To achieve this, the \ac{CRS} can be created by a trusted third party or, more robustly, via a secure \ac{MPC} protocol \cite{canetti2001universally}. In an MPC setup, it suffices that at least one participant discards their secret contribution to ensure the integrity of the whole ceremony. {\color{blue}For \davinci, we run an \ac{MPC} for each of the circuits, see Section~\ref{sec:analysis:implementation} and Appendix~\ref{sec:cryptographic-primitives:zkp}.} % By anchoring these proofs on Ethereum, the protocol ensures that every step of the voting process is publicly verifiable, while preserving voter privacy. %In general, zk-SNARKs for circuit satisfiability (CSAT) require arithmetic circuits to be expressed in a more algebraic form. A common representation is the rank-1 constraint system (R1CS) [GGPR13], which encodes computations as a set of quadratic constraints. A zk-SNARK proof then demonstrates, without revealing any private values, that the prover knows an assignment to all wires of the circuit that satisfies the R1CS. Tooling such as circom provides a high-level language to write arithmetic circuits while still exposing full control over the signals and constraints of the resulting R1CS.
M v2/sections/parties.tex → v2/sections/parties.tex

@@ -4,11 +4,11 @@ An election involves four types of participants: organizer, \keywardens, voters, and sequencers.

\paragraph{Organizer.} The organizer is the entity responsible for defining and setting up the election. Its key responsibilities include defining the voting parameters and gathering the census data. The organizer ensures that the election is structured correctly but does not participate in vote collection or tallying. -\paragraph{\Keywardens.} \Keywardens are a set of decentralized parties that collaboratively generate a public encryption key that voters use to encrypt their votes. +\paragraph{\Keywardens.} \Keywardens are a set of decentralized parties that collaboratively generate a public encryption key that voters use to encrypt their votes. The corresponding secret key is secret-shared among them so that only a threshold of key wardens can later collaborate to decrypt the final tally. %Individual ballots remain private because the protocol only invokes threshold decryption on the final aggregate, not on each ballot separately. \paragraph{Voters.} Voters are the participants that belong the census and are allowed to cast their votes in the election. \\ -\noi {\color{blue}\textbf{TODO}: we need to add that each voter has a secret $\sk$ and public $\pk$ key and an associated Ethereum address. Maybe add something about the weight as well? Consider adding a public-key scheme in Section~\ref{sec:cryptographic-primitives}.} +\noi {\color{blue}\textbf{TODO}: we need to add that each voter has a secret $\sk$ and public $\pk$ key and an associated Ethereum address. Maybe add something about the weight as well? Consider adding a public-key scheme in Appendix~\ref{sec:cryptographic-primitives}.} \paragraph{Sequencers.} Sequencers are a set of parties that during the voting period receive and verify encrypted ballots from voters, reencrypt votes to prevent coercion, and update the shared public state accordingly.
M v2/sections/protocol-flow.tex → v2/sections/protocol-flow.tex

@@ -20,7 +20,7 @@ \item Prepare the voting form (ballot / set of questions), upload it to IPFS, compute commitment.

\item Define the election details, including duration, options, and the ballot rules $\ballotmode$ (see Section~\ref{sec:ballot-protocol}). \item Compute a unique process identifier $\processid$, which is a 32-byte number derived from the organizer’s Ethereum address, nonce, and the chain ID. \item Set security parameters for the %forthcoming - \ac{DKG} ceremony (e.g., timeout, minimum number of sequencers). + \ac{DKG} ceremony (e.g. timeout, minimum number of sequencers). \item Submit all this information in a transaction to the \hlget{\electionregistry} smart contract {\color{blue}(pay tx fees)}: \[ tx_{org} = (\censusroot, ballotCommitment, \ballotmode, electionMetadata, \processid, dkgParameters).\] \end{enumerate}
M v2/sections/protocol-intuition.tex → v2/sections/protocol-intuition.tex

@@ -4,9 +4,9 @@ The following section provides an overview of the DAVINCI protocol, describing its main phases and actors without delving into technical details. The election process is governed by smart contracts deployed on Ethereum, which ensure transparency, enforce rules, and verify proofs. As shown in Figure~\ref{fig:protocol-intuition}, the protocol consists of five main phases, from the setup of the election to the publication and verification of final results.

%All the voting process is governed by the rules encoded in three smart contracts: the \textit{process management}, the \textit{sequencer registry}, and the \textit{results verification} smart contract. All these three contracts are deployed on the Ethereum blockchain, and ensure that the execution of all steps is transparent and unalterable. The protocol consists of five phases, as illustrated in Figure~\ref{fig:protocol-intuition} and described below. The first two occur during the preparation period, the subsequent two during the voting period, and the final one takes place in the tally period. \begin{figure}[h] - \centerline{\includegraphics[width=320pt,draft=false]{\figs/protocol-intuition-flow.pdf}} - \setlength{\abovecaptionskip}{0pt} % Space between figure and caption - \caption{Overview of the protocol flow. {\color{blue}Figure is outdated with respect to new actors and phases.}} + \centerline{\includegraphics[width=490pt,draft=false]{\figs/protocol-intuition-flow.pdf}} + \setlength{\abovecaptionskip}{5pt} % Space between figure and caption + \caption{Overview of the protocol flow.} \label{fig:protocol-intuition} %\setlength{\belowcaptionskip}{0pt} % Space after caption \end{figure}

@@ -16,7 +16,7 @@

\begin{enumerate} \item \textit{Election setup}. In the first phase, the \emph{organizer} gathers all census data and generates a cryptographic commitment to this data. %using a Merkle tree (MT) root. - Additionally, the organizer defines the voting parameters, including the number of voting options and the vote-counting mechanism (e.g., weighted voting, quadratic voting, etc.). Once these details are set, the organizer submits a transaction to the process management smart contract on the Ethereum blockchain. This transaction publicly records the voting parameters and census commitment, ensuring transparency and preventing any subsequent alterations to the voting setup.\\ + Additionally, the organizer defines the voting parameters, including the number of voting options and the vote-counting mechanism (e.g. weighted voting, quadratic voting, etc.). Once these details are set, the organizer submits a transaction to the process management smart contract on the Ethereum blockchain. This transaction publicly records the voting parameters and census commitment, ensuring transparency and preventing any subsequent alterations to the voting setup.\\ % \item \textit{Encryption key generation.} A designated group of participants, referred to as \emph{\keywardens}, collaboratively generate a shared encryption public key, which voters will use to encrypt their votes. This key is established through a \ac{DKG} protocol, ensuring that no single party can control or reconstruct the corresponding private key independently.

@@ -24,7 +24,7 @@ %Sequencers have a dual role in the protocol. In addition to generating the encryption key, they are also responsible for collecting votes from voters during the election. Consequently, their public key and the necessary information to contact them off-chain must be registered in the sequencer registry smart contract.

Once the encryption public key is securely computed and published in the smart contract, the voting period can start.\\ % \item \textit{Voting period}. - During the voting period, two actors interact continuously: \textit{voters}, who cast their encrypted ballots, and \emph{sequencers}, independent entities responsible for collecting, verifying, and processing these ballots before committing them to the shared state. Both processes, ballot submission by voters (\ref{sec:protocol-intuition:vote-casting}) and vote batching by sequencers (\ref{sec:protocol-intuition:vote-batching}), occur continuously and in parallel throughout this phase. + During the voting period, two actors interact continuously: \textit{voters}, who cast their encrypted ballots, and \emph{sequencers}, independent entities responsible for collecting, verifying, and processing these ballots before committing them to the shared state. Both processes, (\ref{sec:protocol-intuition:vote-casting}) ballot submission by voters and (\ref{sec:protocol-intuition:vote-batching}) vote batching by sequencers, occur continuously and in parallel throughout this phase. The voting period remains open until the deadline defined by the organizer, allowing voters to submit or overwrite ballots at any time, while sequencers periodically process new submissions and update the election state accordingly.\\ %to a separate entity called \textit{sequencers}, which are independent participants responsible for collecting, validating, and processing votes before committing them to the shared state.

@@ -32,11 +32,11 @@

\begin{enumerate} \item \label{sec:protocol-intuition:vote-casting} \textit{Vote casting}. Voters select their preferred choices according to the voting rules established by the organizer and captured in the process management smart contract. Instead of submitting their votes directly on-chain, they send them off-chain to a sequencer of their choice for processing. - To ensure privacy, votes are encrypted using the available encryption public key. To ensure privacy, votes are encrypted using the available encryption public key. Additionally, users compute a unique vote identifier that will allow them to verify that their vote has been included in the final result. Alongside the encrypted vote and the vote identifier, each voter must also provide the following data: a proof of valid voting, demonstrating that the vote complies with the election rules; a proof of eligibility, verifying that they are registered in the census; and a proof of identity ownership, in the form of a digital signature, confirming that they are the legitimate voter and are not impersonating someone else. To mitigate coercion and vote-buying, the protocol allows voters to overwrite their vote any number of times during the voting phase. \\ + To ensure privacy, votes are encrypted using the available encryption public key. Additionally, voters compute a unique vote identifier that will allow them to verify that their vote has been included in the final result. Alongside the encrypted vote and the vote identifier, each voter must also provide the following data: a proof of valid voting, demonstrating that the vote complies with the election rules; a proof of eligibility, verifying that they are registered in the census; and a proof of identity ownership, in the form of a digital signature, confirming that they are the legitimate voter and are not impersonating someone else. To mitigate coercion and vote-buying, the protocol allows voters to overwrite their vote any number of times during the voting phase. \\ % \item \label{sec:protocol-intuition:vote-batching} \textit{Vote batching}. During this phase, sequencers collect encrypted votes from multiple voters along with their corresponding proofs, and verify the validity of these submissions. That is, sequencers - verify the signatures, to ensure the votes were cast by legitimate voters; they verify the proof of compliance, confirming that each vote adheres to the polling rules, and the census membership proofs against the commitment to the census data that was originally registered in the process management smart contract. Once the sequencers have processed and verified all votes, they must prove that these verifications were performed correctly. Instead of submitting individual verifications for each vote, they generate a single ZK proof that attests to the correctness of all verifications. + verify the signatures, to ensure the votes were cast by legitimate voters; they verify the proof of compliance, confirming that each vote adheres to the election voting rules, and the census membership proofs against the commitment to the census data that was originally registered in the process management smart contract. Once the sequencers have processed and verified all votes, they must prove that these verifications were performed correctly. Instead of submitting individual verifications for each vote, they generate a single \ac{ZK} proof that attests to the correctness of all verifications. %they compress multiple individual verification into one. Additionally, the sequencers reencrypt the votes and generate a proof of the correct reencryption computation. While this process does not alter the final tally, it prevents voters from decrypting their original vote. This step mitigates vote selling or coercion, as voters are no longer able to prove their choice to third parties. Finally, sequencers submit the reencrypted votes along with their verification and reencryption proofs to the process management smart contract. The smart contract verifies all the proofs provided by the sequencers to check that they complied with the protocol.\\ \end{enumerate}
M v2/sections/smart-contracts.tex → v2/sections/smart-contracts.tex

@@ -1,6 +1,6 @@

% !TeX root = ../build/main.tex -The \davinci protocol operates on an Ethereum-compatible network, which serves as the source of truth for the election. By leveraging an Ethereum virtual machine (EVM) blockchain, all election transitions become immutable and publicly verifiable. To coordinate and validate each phase of the process, DAVINCI deploys a set of smart contracts that enforce protocol rules, verify zero-knowledge proofs, and maintain on-chain commitments such as state roots, encryption keys, and final results. Together, these contracts provide a trustless execution environment that guarantees the correct and transparent progression of the election without relying on any centralized authority. +The \davinci protocol operates on an Ethereum-compatible network, which serves as the source of truth for the election. By leveraging an Ethereum virtual machine (EVM) blockchain, all election transitions become immutable and publicly verifiable. To coordinate and validate each phase of the process, DAVINCI deploys a set of smart contracts that enforce protocol rules, verify \ac{ZK} proofs, and maintain on-chain commitments such as state roots, encryption keys, and final results. Together, these contracts provide a trustless execution environment that guarantees the correct and transparent progression of the election without relying on any centralized authority. \noi {\color{blue}\textbf{TODO}: add methods and state variables.} \subsubsection{Organization registry}
M v2/sections/vocdoni-protocol.tex → v2/sections/vocdoni-protocol.tex

@@ -1,6 +1,11 @@

% !TeX root = ../build/main.tex -This section outlines the \davinci voting protocol. First, we introduce the parties involved in the process in Section~\ref{sec:vocdoni-protocol:parties}. In Section~\ref{sec:vocdoni-protocol:census}, we describe the census data structures and in Section~\ref{sec:vocdoni-protocol:state-tree} the state Merkle trees. Then, in Section~\ref{sec:vocdoni-protocol:smart-contracts} we present the Ethereum smart contracts that rule the \davinci protocol. In Section~\ref{sec:vocdoni-protocol:circuits}, we present the ZK circuits used to enforce vote validity, authentication, aggregation, state transitions, and results computation. Finally, in Section~\ref{sec:vocdoni-protocol:flow}, we detail the full protocol flow step by step, from the voting setup to the results validation and process finalization. +This section outlines the \davinci voting protocol. +First, we introduce the parties involved in the process in Section~\ref{sec:vocdoni-protocol:parties}. +In Section~\ref{sec:vocdoni-protocol:smart-contracts} we present the Ethereum smart contracts that rule the \davinci protocol. +Then, in Section~\ref{sec:vocdoni-protocol:census}, we describe the census data structures and in Section~\ref{sec:vocdoni-protocol:state-tree} the state Merkle trees. +In Section~\ref{sec:vocdoni-protocol:circuits}, we present the \ac{ZK} circuits used to enforce vote validity, authentication, aggregation, state transitions, and results computation. +Finally, in Section~\ref{sec:vocdoni-protocol:flow}, we detail the full protocol flow step by step, from the voting setup to the results validation and process finalization. \subsection{Parties involved} \label{sec:vocdoni-protocol:parties}