dedis / cothority

Scalable collective authority
Other
425 stars 106 forks source link

Additional votes in the structures #2506

Open ineiti opened 1 year ago

ineiti commented 1 year ago

What this PR does

For a new election at EPFL there will be more than 8 candidates. This is a problem, as currently all choices are stored as data in an ed25519 Point. But as this Point only takes 24 bits of data, we cannot store easily more than 9 choices.

To allow for more than 9 candidates, each Ballot, Mix, and Partial will have Additional* fields to hold the additional choices. As these fields are slices, and added to the end of the structures, and thus to the end of the protobuf definition, it should be backward-compatible. To make sure we don't add security problems, we also do:


🙅‍ Friendly checklist:

sonarcloud[bot] commented 1 year ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 6 Code Smells

No Coverage information No Coverage information
0.9% 0.9% Duplication