diff --git a/local.properties_does_not_work b/local.properties_does_not_work new file mode 100644 index 0000000..1079495 --- /dev/null +++ b/local.properties_does_not_work @@ -0,0 +1 @@ +sdk.dir=C\:/Users/Laura/AppData/Local/Android/sdk \ No newline at end of file diff --git a/meerkat-common/src/main/proto/meerkat/voting.proto b/meerkat-common/src/main/proto/meerkat/voting.proto index 298726d..5e5991f 100644 --- a/meerkat-common/src/main/proto/meerkat/voting.proto +++ b/meerkat-common/src/main/proto/meerkat/voting.proto @@ -81,6 +81,7 @@ message BallotSecrets { EncryptionRandomness encryption_randomness = 2; RandomnessGenerationProof proof = 3; + uint64 serial_number = 4; // Ballot serial number } message SignedBallotSecrets { diff --git a/scanner-api-common/src/main/proto/meerkat/polling_station.proto b/scanner-api-common/src/main/proto/meerkat/polling_station.proto index 2186241..5cbfb5b 100644 --- a/scanner-api-common/src/main/proto/meerkat/polling_station.proto +++ b/scanner-api-common/src/main/proto/meerkat/polling_station.proto @@ -41,6 +41,11 @@ message ScannedBallot { } +//Container for auditing messages +message ScannedAudit { + SignedBallotSecrets signed_ballot_secrets = 1; +} + // Container for error messages message ScanError { string msg = 1; @@ -49,12 +54,14 @@ message ScanError { // Container for scanned data message ScannedData { + uint64 serial = 1; // Serial number of the message + bytes scannerId = 2; // hash of the scannerPK oneof data { - ScannedBallot ballot = 2; - ScanError error = 3; + ScannedBallot ballot = 3; + ScanError error = 4; + ScannedAudit audit_ballot = 5; } - uint64 serial = 4; // Serial number of the message - bytes scannerId = 5; // hash of the scannerPK + } message SignedScannedData { diff --git a/voting-booth-gui/src/main/java/meerkat/voting/gui/output/FXWindowOutputDevice.java b/voting-booth-gui/src/main/java/meerkat/voting/gui/output/FXWindowOutputDevice.java index 549d89a..d22e78a 100644 --- a/voting-booth-gui/src/main/java/meerkat/voting/gui/output/FXWindowOutputDevice.java +++ b/voting-booth-gui/src/main/java/meerkat/voting/gui/output/FXWindowOutputDevice.java @@ -59,8 +59,8 @@ public class FXWindowOutputDevice extends AsyncRunnableOutputDevice { logger.debug("entered method doAudit"); VistaNavigator.printFXSeparator(); BallotSecrets ballotSecrets = command.getBallotSecrets(); - printEncryptionRandomness(ballotSecrets.getEncryptionRandomness()); - printRandomnessGenerationProof (ballotSecrets.getProof()); +// printEncryptionRandomness(ballotSecrets.getEncryptionRandomness()); +// printRandomnessGenerationProof (ballotSecrets.getProof()); printAuditBallot(ballotSecrets); command.getCallback().onSuccess(null); } @@ -146,7 +146,9 @@ public class FXWindowOutputDevice extends AsyncRunnableOutputDevice { toPrint+="\n"; VistaNavigator.printFX(toPrint); - //generate the PollingStation. corresponding to [plaintext, randomness, Signed(plaintext, randomness)] + //generate the PollingStation. corresponding to [ballotID, plaintext, randomness, Signed(ballotID, plaintext, randomness)] + PollingStation.ScannedAudit scannedAudit = PollingStation.ScannedAudit.newBuilder() + .setSignedBallotSecrets(ballotSecrets); // PollingStation.ScannedBallot scannedBallot = PollingStation.ScannedBallot.newBuilder() // .setChannel(command.getChannelIdentifierByteString()) // .setSignedEncryptedBallot(command.getSignedEncryptedBallot())