# Difference between revisions of "Practical Quantum Electronic Voting"

This example protocol achieves the functionality of Quantum Electronic Voting. In this protocol, an untrusted multipartite entanglement source can be used to carry out an election without any election authorities.

## Outline

• In the first phase of the protocol, each agent is assigned a secret unique random index
• Next, we perform multiple rounds of voting, one for each agent. In each round, the following steps are carried out:
• The agent with the same index as the round number is designated the voter for that round
• The source distributes one qubit of a GHZ state to each agent. The voting agent randomly chooses to either verify the GHZ state or vote with a certain probability. This step, including state distribution, is repeated until the voter chooses to vote. Once voting is chosen, the voter anonymously transmits their vote to all agents.
• Finally, all the votes are tallied. All agents have the votes for each round and can thus verify the final tally.

## Notation

• $N$ : Number of agents
• $V=\{v_{k}\}_{k\in [N]}$ : The votes
• $S$ : Security parameter
• $\epsilon$ : Distance from the perfect GHZ state
• $\delta$ : Threshold for verification
• $\eta$ : Probability of failure of verification
• B: Bulletin board - $N$ x $N$ binary matrix. Each row corresponds to one round of voting, and each column contains the output of a single voter across all rounds
• E: Vote vector - The list of votes across $N$ rounds. Each element is computed as the parity of a row from B
• T: Final tally

## Protocol Description

### Protocol 1 : Quantum e-voting

Inputs: $V=\{v_{k}\}_{k\in [N]}$ - Set of votes; $S$ - Security parameter; $\epsilon$ - Distance from the perfect GHZ state; $\delta$ - Threshold for verification; $\eta$ Probability of failure of verification

Output: The candidate with majority votes or Abort

Resources: Classical communication, random numbers, N-qubit GHZ source, quantum channels

• Phase 1 [getting unique secret indices]
• Agents perform UniqueIndex until each agent has a secret unique random index $\omega _{k}$ • For $l=1$ to $N$ • The voting agent is the agent $k$ with $\omega _{k}=l$ • Repeat until Voting is announced
• The source distributes to each of the N agents one qubit of the GHZ source
• All agents $j\in [N]$ set rejections$_{j}=$ trials$_{j}=0$ • The voting agent tosses log$_{2}[{\frac {16N\epsilon ^{2}}{(\epsilon ^{2}-4\delta )^{2}}}$ ln$({\frac {1}{\eta }})]$ • The agents perform LogicalOR, where output 1 indicates Verification and output 0 indicates Voting. Everyone except the voting agent inputs 0; if the coin toss is 'all heads' the voting agent also inputs 0, otherwise the voting agent inputs 1
• If Verification is chosen, the agents perform RandomAgent and the voting agent anonymously picks an agent $j\in [N]$ to be the verifier. Agent $j$ updates trials$_{j}+=1$ and if Verification outputs reject: rejections$_{j}+=1$ • If for any $j\in [N],\delta _{j}={\frac {rejections_{j}}{trials_{j}}}>\delta$ , the protocol Aborts
• Perform Voting. The outcome is one row of the Bulletin Board B. The parity of the row gives one entry in the vote vector E.
• Given the votes E, the tally T can be computed.
• Phase 3 [Verification of results]:
• All agents perform LogicalOR with security parameter $S$ , and input 1 if their vote is not the same as the entry in E for the round in which they voted, and 0 otherwise.
• If LogicalOR outputs 1, Abort the protocol. Else output the candidate with the most votes according to the tally T.

### Protocol 2 : LogicalOR

Inputs: $N$ agents, $N$ boolean variables $x_{i}$ , security parameter $S=(1-2^{-\Gamma })^{\Sigma }\in (0,1)$ Output: $y=\vee _{i}^{N}x_{i}$ Resources: Classical communication and random numbers

1. Decide $N$ random orderings, such that each voter is the last once. For each ordering repeat \Sigma times the following.
2. Each voter $k$ gives an input $x_{k}$ 3. If $x_{k}=0$ , set $p_{k}=0$ , otherwise toss $\Gamma$ coins and set $p_{k}$ to $1$ if the result is ‘all heads’ and to $0$ otherwise
4. Then each voter generates uniformly at random an $N$ -bit string $r_{k}=r_{k}^{1}r_{k}^{2}...r_{k}^{N}$ , such that $\bigoplus _{i=1}^{N}r_{k}^{i}=p_{k}$ 5. Voter $k$ sends $r_{k}^{i}$ to voter $i$ for all $i$ , keeping $r_{k}^{k}$ 6. Each voter sums the received bits and broadcasts the parity $z_{i}=\bigoplus _{k=1}^{N}r_{k}^{i}$ according to the ordering.
7. Compute the parity of the original bits $y=\bigoplus _{i}z_{i}$ 8. From this everyone can also compute the parity of all other inputs except their own $w_{k}=\bigoplus _{i=1}^{N}(z_{i}\otimes r_{k}^{i})$ 9. Repeat $\Sigma$ times from step 4: each time repeat with $p_{k}$ as new inputs
10. If at least once in the $\Sigma$ repetitions for the various orderings $y=1$ , this is the output of the protocol, otherwise it is $y=0$ ### Protocol 3 : RandomBit

Input: Security parameter S to be used in LogicalOR, voting agent: probability distribution D.

Output: The voting agent anonymously announces a random bit according to D.

Resources: Classical communication and random numbers.

• Perform LogicalOR with security parameter S where the voting agent inputs a random bit according to D and the other agents input 0.

### Protocol 4 : RandomAgent

Input: Security parameter S to be used in RandomBit, voting agent: probability distribution D.

Output: The voting agent anonymously chooses a random agent according to D.

Resources: Classical communication and random numbers.

### Protocol 5 : UniqueIndex

Input: Security parameter $S$ to be used in LogicalOR,$N$ random boolean variables $x_{i}$ .

Output: Each agent $k$ has a secret unique index $\omega _{k}$ .

Resources: Classical communication and random numbers.

1. Beginning of round R = 1
2. Agents perform LogicalOR with inputs $x_{k}=0$ if they already have an index and $x_{k}=1$ if they do not.
3. If $y=0$ , repeat from step 2
4. If an agent $k$ has a bit $x_{k}=1$ and $\omega _{k}=0$ they know they are the only one and has been assigned the secret index corresponding to the round $\omega _{k}=R$ , otherwise there is a collision.
5. $notification$ Everybody performs a LogicalOR with input 0, unless they received the index in this round, in which case they input 1.
6. If the output of LogicalOR is 0, no index was assigned and we repeat from step 2.
7. If the output of LogicalOR is 1, the index was assigned and we repeat from step 2 with R+ = 1.
8. Repeat from step 2 until all indices have been assigned.

### Protocol 6 : Verification

Input: A quantum state distributed and shared by $N$ parties, security parameter $S$ for RandomAgent.

Output: If the state is a GHZ state $\rightarrow$ YES.

Resources: Classical communication, random numbers, quantum state source, quantum channels.

1. Everyone executes RandomAgent to choose uniformly at random one of the voters to be the verifier.
2. The verifier generates random angles $\theta _{j}\in [0,\pi )$ for all agents including themselves, such that the sum is a multiple of $\pi$ . The angles are then sent out to all the agents.
3. Agent $j$ measures in the basis $[|+_{\theta }\rangle ,|-_{\theta }\rangle ]=[{\frac {1}{\sqrt {2}}}(|0\rangle +e^{i\theta _{j}}|1\rangle ),{\frac {1}{\sqrt {2}}}(|0\rangle -e^{i\theta _{j}}|1\rangle )]$ and publicly announces the result $Y_{j}=\{0,1\}$ 4. The state passes the verification test when the following condition is satisfied: if the sum of the randomly chosen angles is an even multiple of $\pi$ , there must be an even number of 1 outcomes for <math<Y_j[/itex] , and if the sum is an odd multiple of $\pi$ , there must be an odd number of 1 outcomes for $Y_{j}:\bigoplus _{j}Y_{j}={\frac {1}{\pi }}\sum _{i}\theta _{i}$ ### Protocol 7 : Voting

Input: Voting agent preference $v_{k}$ .

Output: All agents get one row of the bulletin board.

Resources: Classical communication, GHZ source, quantum channels.

1. Each agent measures the state they received in the Hadamard basis and records the outcome.
2. The outcomes of the measurement of each voter $k$ is $d_{k}$ . Then we know that $\sum _{k}d_{k}=0$ mod $2$ 3. The voting agent performs an XOR between the outcome $d_{k}$ and their vote $v_{k}$ : $d_{k}\leftarrow d_{k}\oplus v_{k}$ . However, this alone will still appear as a random string.
4. Every agent publicly broadcasts $d_{k}$ which gives one line $b_{k}$ of the bulletin board B $=\{b_{k}\}$ 