Closed elboletaire closed 9 months ago
There's an issue with the implementation.. the SIK should be checked in the SpreadsheetAccess
component, since right now it's not checked and it can cause a bad UX. To check it (copy-pasted from a chat with marcvelmer):
const sik = await AnonymousService.calcSik(address, signature, password)
const checkSik = await await client.anonymousService.fetchAccountSIK(address)
edit: also, the ConfirmModal does not appear for non-anonymous elections now 🙄
Anonymous elections are kinda special, since they have an additional security layer with a custom password, known as SIK.
Due to this layer having a password, and because it is required to get the nullifier (and vote id), anonymous elections should require it, prompting logged in users the very first time they access an anonymous election (such call result should be stored in state to avoid future calls).
Since we'll have to prompt users for their password, the logic of this implementation may be both in
react-providers
and/orchakra-components