|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object auditor.PreElectionAudit
public class PreElectionAudit
Class that runs pre election audit for Scantegrity elections
Field Summary | |
---|---|
private int[] |
ballotsOpenedForAudit
table of ballot's indexes opened for audit read from MeetingTwoOut.xml: xml/database/print/ row[id] |
private int[] |
ballotsRequestedForAudit
table of ballot's indexes requested for audit read from MeetingTwoIn.xml: xml/challenges/print/ row[id] |
private java.lang.String[] |
c1
Commitments to P table read from MeetingOneOut.xml: xml/database/print/row s1/s2 |
private java.lang.String[] |
c2
|
private java.lang.String |
electionConstant
Election Constant read from MeetingOneIn.xml: xml/constant |
private int[] |
maxNumberOfAnswersSelected
|
private int[] |
numberOfAnswers
|
private int |
numberOfBallots
No of ballots read from MeetingOneIn.xml: xml/noBallots |
private int |
numberOfDTables
No of D Tables read from MeetingOneIn.xml: xml/noDs |
private int |
numberOfQuestions
|
private java.lang.String[] |
p1
|
private java.lang.String[] |
p2
|
private Partition[] |
partitionCommitments
|
private int[] |
startFrom
|
private java.lang.String[] |
typeOfAnswerChoice
|
Constructor Summary | |
---|---|
PreElectionAudit(java.lang.String path)
|
Method Summary | |
---|---|
static void |
main(java.lang.String[] args)
Method that runs post-audit check of table RS, RM and RF |
private void |
readElectionSpec(java.lang.String path,
java.lang.String xmlFilename)
Method parses ElectionSpec.xml - reads information about questions (number of questions, type of questions, number of answers) |
private void |
readMeetingOneIn(java.lang.String path,
java.lang.String xmlFilename)
Method parses MeetingOneIn.xml and checks: |
private void |
readMeetingOneOut(java.lang.String path,
java.lang.String xmlFilename)
Method checks: if the number of rows in the print element is the same as the number of ballots in MeetingOneIn.xml if the number of rows in each instance in a partition element is the same as noBallots in MeetingOneIn.xml if the number of instances in each partition element is the same as noDs in MeetingOneIn.xml |
private void |
readMeetingTwoIn(java.lang.String path,
java.lang.String xmlFilename)
Parses meetingTwoIn and reads id's of ballots requested for audit |
private void |
readMeetingTwoOut(java.lang.String path,
java.lang.String xmlFilename)
Parses MeetingTwoOut.xml - reads id's of ballots opened for audit - then checks if commitments to p1 and p2 for these ids are formed correctly - then checks for all D-tables if commitments to d2 and d4 are correct verify if d2(d4) = p2(p1^-1) |
private void |
testRequestedData()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private int numberOfBallots
private int numberOfDTables
private java.lang.String electionConstant
private java.lang.String[] c1
private java.lang.String[] c2
private Partition[] partitionCommitments
private int[] ballotsRequestedForAudit
private int[] ballotsOpenedForAudit
private java.lang.String[] p1
private java.lang.String[] p2
private int numberOfQuestions
private int[] numberOfAnswers
private int[] startFrom
private java.lang.String[] typeOfAnswerChoice
private int[] maxNumberOfAnswersSelected
Constructor Detail |
---|
public PreElectionAudit(java.lang.String path)
Method Detail |
---|
private void testRequestedData() throws java.lang.Exception
java.lang.Exception
private void readElectionSpec(java.lang.String path, java.lang.String xmlFilename) throws java.lang.Exception
path
- - path to the folder with election filesxmlFilename
-
java.lang.Exception
private void readMeetingOneIn(java.lang.String path, java.lang.String xmlFilename) throws java.lang.Exception
path
- xmlFilename
-
java.lang.Exception
private void readMeetingOneOut(java.lang.String path, java.lang.String xmlFilename) throws java.lang.Exception
path
- xmlFilename
-
java.lang.Exception
private void readMeetingTwoIn(java.lang.String path, java.lang.String xmlFilename) throws java.lang.Exception
xmlFilename
- - path to the meetingTwoIn
java.lang.Exception
private void readMeetingTwoOut(java.lang.String path, java.lang.String xmlFilename) throws java.lang.Exception
xmlFilename
- - name of the file to open (usualy meetingTwoOut.xml)path
- - path to the folder with election files
java.lang.Exception
- - if commitments are not correctpublic static void main(java.lang.String[] args)
args
-
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |