Re: Refactring FIPS_escda_sign() for OpenSSL 3.0.0

2021-10-29 Thread Matt Caswell
On 28/10/2021 22:46, Kory Hamzeh wrote: Hi Matt, I am making the changes that you suggested, I think I can get the X and Y by using EVP_PKEY_get_bn_param() with OSSL_PKEY_PARAM_EC_PUB_X and _PUB_Y. Yes. Correct. What I cannot figure out is how to get R and S. If I had an ECDSA_SIG, I w

Re: Refactring FIPS_escda_sign() for OpenSSL 3.0.0

2021-10-28 Thread Kory Hamzeh
Hi Matt, I am making the changes that you suggested, I think I can get the X and Y by using EVP_PKEY_get_bn_param() with OSSL_PKEY_PARAM_EC_PUB_X and _PUB_Y. What I cannot figure out is how to get R and S. If I had an ECDSA_SIG, I would call ECDSA_SIG_get0_r() and _s(). Are there EVP_PKEY p

Re: Refactring FIPS_escda_sign() for OpenSSL 3.0.0

2021-10-28 Thread Matt Caswell
On 27/10/2021 19:04, Kory Hamzeh wrote: Hi, I am upgrading some 3RD party code which performs FIPS ECDSA AVS testing for FIPS 140-2 certification. The code uses FIPS_escda_sign(), which in Openssl-fips-2.0.5 is define as: ECDSA_SIG * FIPS_ecdsa_sign(EC_KEY *key, co

Refactring FIPS_escda_sign() for OpenSSL 3.0.0

2021-10-27 Thread Kory Hamzeh
Hi, I am upgrading some 3RD party code which performs FIPS ECDSA AVS testing for FIPS 140-2 certification. The code uses FIPS_escda_sign(), which in Openssl-fips-2.0.5 is define as: ECDSA_SIG * FIPS_ecdsa_sign(EC_KEY *key, const unsigned char *msg, size_t msglen ,