solokeys / solo1

Solo 1 firmware in C
https://solokeys.com/
Other
2.29k stars 273 forks source link

Leverage SECP256k1 with FIDO2 #414

Open tomer-mayara opened 4 years ago

tomer-mayara commented 4 years ago

It looks like the code might support SECP256K1 (solo/fido2/extensions/wallet.c) with FIDO2 How should I structure the MakeCredential call to use 256k1 instead of 256r1? What is the Alg value (since it is not defined in the CBOR standard)?

Thanks!

nickray commented 4 years ago

(I strongly think) we shouldn't support non-COSE algorithms in official firmware. Would also prefer not to get into the discussion of why it's not on the list (IETF CFRG mailing list has some discussion on this, it's a bit "flamey" as a topic).

Underlying micro-ecc does implement the "Bitcoin curve". You'd have to pick your own alg-value from the "Reserved for Private Use" range (https://www.iana.org/assignments/cose/cose.xhtml#algorithms), and reconfigure the relevant pieces of code.

Note that currently the firmware has hard-coded assumptions on all keys being for the same curve (and that P256 is mandatory for attestation).