I'm developing a client for a two-factor authentication in Qt/C++ under openSUSE 13.2, 64bit. I've got the FIDO U2F Security Key from yubico/fido.
I'm using the classes from openssl, in particular
The registration went smoothly, so I can get the $r$ and $s $from the signature. I can also check whether the point lies on the curve (so I've got the public key, too).
My actual problem is to verify the signature. I have to use the curve P-256 from NIST. I've tried it with
ECDSA_do_verify, but I don't know how to set my public key. Also, I think I will not get the private key. So, I think that this methods are not useful for me. Therefore I want to develop own methods to verify my signature. I've studied the ECDSA algorithm, but I don't know where I should begin. I know what to do, but I'm unsure how to implement in my program.
I'd be very glad if anyone has an idea which could help me. Thanks a lot :)