Re: [openssl-dev] Access to ECDSA_METHOD do_verify function from engine

2017-07-21 Thread Johannes Bauer
On 21.07.2017 16:10, Tomas Mraz wrote: > On Fri, 2017-07-21 at 15:56 +0200, Johannes Bauer wrote: >> I've changed my code now to also use the (mutable) new >> EC_KEY_METHOD*, >> which doesn't give a diagnostic. Regardless, I believe that the first >> parameter of EC_KEY_METHOD_get_sign should be

Re: [openssl-dev] Access to ECDSA_METHOD do_verify function from engine

2017-07-21 Thread Tomas Mraz
On Fri, 2017-07-21 at 15:56 +0200, Johannes Bauer wrote: > I've changed my code now to also use the (mutable) new > EC_KEY_METHOD*, > which doesn't give a diagnostic. Regardless, I believe that the first > parameter of EC_KEY_METHOD_get_sign should be const EC_KEY_METHOD*, > not > EC_KEY_METHOD*.

Re: [openssl-dev] Access to ECDSA_METHOD do_verify function from engine

2017-07-21 Thread Johannes Bauer
On 21.07.2017 15:08, Douglas E Engert wrote: > I don't see your problem with OpenSSL-1.1.0f. I don't recall seeing it with > earlier version either. p11_ec.c does: > > > 647 static EC_KEY_METHOD *ops = NULL; > 648 int (*orig_sign)(int, const unsigned char *, int, unsigned > char

Re: [openssl-dev] Access to ECDSA_METHOD do_verify function from engine

2017-07-21 Thread Douglas E Engert
On 7/21/2017 7:19 AM, Johannes Bauer wrote: On 21.07.2017 14:00, Douglas E Engert wrote: It uses either: ops = ECDSA_METHOD_new((ECDSA_METHOD *)ECDSA_OpenSSL()); or ops = EC_KEY_METHOD_new((EC_KEY_METHOD *)EC_KEY_OpenSSL()); which copy the default structure to the new opaque

Re: [openssl-dev] Access to ECDSA_METHOD do_verify function from engine

2017-07-21 Thread Johannes Bauer
On 21.07.2017 14:00, Douglas E Engert wrote: > It uses either: > ops = ECDSA_METHOD_new((ECDSA_METHOD *)ECDSA_OpenSSL()); > or > ops = EC_KEY_METHOD_new((EC_KEY_METHOD *)EC_KEY_OpenSSL()); > > which copy the default structure to the new opaque structure. > It then sets the routines it

Re: [openssl-dev] Access to ECDSA_METHOD do_verify function from engine

2017-07-21 Thread Douglas E Engert
First of all the ECDSA_METHOD and ECDH_METHOD in 1.0.2 are combined into EC_KEY_METHOD on 1.1. Both versions have a *_new and *_set_verify. "static ECDSA_METHOD my_own_openssl_ecdsa_meth" will not work anymore. Have a look at: https://github.com/OpenSC/libp11/blob/master/src/p11_ec.c It