zk-passport / proof-of-passport

Proof of passport protocol using zk-SNARKs
https://proofofpassport.com
260 stars 38 forks source link

Gracefully handle unsupported signature algorithms #79

Closed 0xturboblitz closed 2 months ago

0xturboblitz commented 4 months ago

Right now, we only support sha256 with RSA as a signature algorithm.

This check is currently commented, which means people who have an unsupported signature algorithm to go the proving step and everything breaks.

The reason I commented it is that I encountered a passport that we supported but that had not the right sig alg name, as the NFC reading libs for iOS and Android we use use different names.

To remediate that, I did this function using these names. It should work, so after testing on both platforms we should bring back the check. Probably also display a toast or a screen telling the person what his sig alg is, maybe how they can contribute, etc.

Kind of a similar question for here and here: we should think about how to handle those gracefully for the user.

0xturboblitz commented 2 months ago

Closing, this is done.