Skip to content

benadida/scantegrity-audit

Repository files navigation

The code for auditing a Scantegrity election

- commitment.py

the Scantegrity commitment scheme.
Requires PyCrypto

==================

Each file that follows is used for one step of the audit. In each case,
an election data directory is provided as input, e.g.

  python meeting1.py <ELECTION_DATA_DIR>
  
This election data directory is expected to contain all of the XML files needed
up to this point in the verification. For example, when running meeting1.py,
the following files are expected:

  MeetingOneIn.xml
  MeetingOneOut.xml
 
The verification programs are stateless: they reload all of the data they need at that point.
This may make them slower than absolutely necessary, but it also prevents potential issues
with data storage, with forgetting to run one verification, etc...

Any signatures of the outputs are performed separately, these programs just run the verification.

- meeting1.py

python meeting1.py {DATA_DIR}

verify the basic parameters

In the case of the Takoma Park Election, the DATA_DIR is a specific ward, so this command needs to be run 6 times.

- meeting2.py

python meeting2.py {DATA_DIR}

verify the audit of the P and D tables.
*IMPORTANT*, the random seed data must be added in the election directory, the one that contains MeetingTwoIn.xml and MeetingTwoOut.xml,
with name pre-election-random-data.txt

In the case of the Takoma Park Election, the DATA_DIR is a specific ward, so this command needs to be run 6 times.

- meeting3.py

python meeting3.py {DATA_DIR}

In the case of the Takoma Park Election, the DATA_DIR is a specific ward, so this command needs to be run 6 times.

If you want to get the confirmation codes, you need to run

python meeting3.py {DATA_DIR} {CONFIRMATION_CODE_FILE_PATH}

- tally

python tally.py {QUESTION_ID} {DATA_PATH_1} {DATA_PATH_2} ...

In the case of the Takoma Park election, question_id 0 needs all 6 data paths,
while question_id 1 is run independently on each ward.

- meeting4.py

- contestedballots.py

- spoiledballots.py

About

Audit Code for the Scantegrity Voting System

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages