arekinath / PivApplet

PIV applet for JavaCard 2.2.2 and 3.0.4+ with full ECDSA/ECDH support
111 stars 37 forks source link

GENERATE ASYMMETRIC KEY PAIR for ECC Keys adds extra byte #30

Closed dengert closed 4 years ago

dengert commented 4 years ago

See: https://github.com/OpenSC/OpenSC/issues/2028#issuecomment-627579440

The response is not the same as from a real NIST PIV card. This may cause problems with Yubico-piv-tool.

arekinath commented 4 years ago

Ah yes, I see. It's calling wtlv.push256() instead of getting the real length so it can guarantee it's DER. Part of the changes for P-384 support. I'll get it fixed up, sorry.

Jakuje commented 4 years ago

The current master works fine. Thanks.