Hello,

I'm still working on porting libjwt https://github.com/benmcollins/libjwt from openssl to gnutls.

The last problem I have is about ECDSA signatures. If I use a GNUTLS_PK_EC private key to sign the data with gnutls_privkey_sign_data, the libjwt unit tests fail.

I see in the openssl version of libjwt that after signing the data, that it converts to a raw format of R/S, by decoding the signature:
https://github.com/benmcollins/libjwt/blob/master/libjwt/jwt-openssl.c#L264

For the verification procedure, it converts back the signature to ASN1:
https://github.com/benmcollins/libjwt/blob/master/libjwt/jwt-openssl.c#L386

Are there equivalent functions to encode/decode ECDSA signatures in GnuTLS?

Thanks in advance

_______________________________________________
Gnutls-help mailing list
[email protected]
http://lists.gnupg.org/mailman/listinfo/gnutls-help

Reply via email to