arnaucube
arnaucube/davinci-paperPublic Self-hosted repository
davinci-paper/v2/sections/protocol-intuition.tex
v2/sections/protocol-intuition.texRaw
 1% !TeX root = ../build/main.tex
 2
 3The following section provides an overview of the DAVINCI protocol, describing its main phases and actors without delving into technical details. An election is governed by smart contracts deployed on Ethereum, which ensure transparency, enforce rules, and verify proofs. As shown in Fig.~\ref{fig:protocol-intuition}, the protocol consists of five main phases, from the setup of the election to the publication and verification of the final results. 
 4%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.
 5
 6\begin{figure}[h]	
 7	\centerline{\includegraphics[width=490pt,draft=false]{\figs/protocol-intuition-flow.pdf}}
 8	\setlength{\abovecaptionskip}{5pt} % Space between figure and caption
 9	\caption{Overview of the protocol flow.}
10	\label{fig:protocol-intuition}
11	%\setlength{\belowcaptionskip}{0pt} % Space after caption
12\end{figure}
13
14%\vspace{-0.5cm}
15
16\begin{enumerate}
17	\item \textit{Election setup}. 
18	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. 
19	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.\\
20	%
21	\item \textit{Encryption key generation.} 
22	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.
23	%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. 
24	Once the encryption public key is securely computed and published in the smart contract, the voting period can start.\\
25	%
26	\item \textit{Voting period}. 
27	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.
28	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.\\
29	
30	%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. 
31			
32	\begin{enumerate}
33		\item \label{sec:protocol-intuition:vote-casting} \textit{Vote casting}.
34		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.
35		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. \\
36		%
37		\item \label{sec:protocol-intuition:vote-batching} \textit{Vote batching}.
38		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
39		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.
40		%they compress multiple individual verification into one.
41		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.\\
42	\end{enumerate}
43
44	\item \textit{Tally decryption}. 
45	At the end of the voting period, the smart contract ceases to accept new state updates. %,effectively finalizing the process.
46	Then, a threshold number of key wardens cooperate to reconstruct a partial decryption key that allows to decrypt the final tally. 
47%	the key wardens cooperate to open the final encrypted tally. Each of them contributes a verifiable decryption share, and once enough such shares have been published, the election outcome can be recovered. This ensures that ballots stay encrypted during the election while still allowing the final result to be publicly obtained and audited once voting has closed.
48%	the key wardens collaborate to enable the decryption of the final tally. 
49	That is, instead of reconstructing the election's private key, each key warden publishes a partial decryption together with a proof that the contribution is correct. 
50	%As soon as a threshold number of valid partial decryptions has been made available, the encrypted tally can be opened and the plaintext results can be recovered. 
51	This way, the individual votes remain encrypted throughout the voting period, and only the final aggregated result is decrypted at the end of the election.
52	\\
53	%
54	\item \textit{Election finalization}.	
55	%At the end of the voting period, the smart contract ceases to accept new state updates, effectively finalizing the process.
56	The results and a proof of correctness are submitted to the results verification smart contract. The contract verifies the proof, ensuring that the tally has been derived faithfully from the final state. Once this verification succeeds, the results and the latest state root remain available on-chain, providing an immutable record of the election outcome that can be independently audited by anyone.
57\end{enumerate}