If the digital signature in ECC (ECDSA) is made using a private key, why is the OpenSSL library using ECKEY pair as an input parameter instead of the private key only ?


1 Answer 1


ECKEY object may contain:

  • Group
  • Private key
  • Public key

Both Group and Private key are needed to be able to calculate signature. It is most convenient to use generic ECKEY object (from API perspective), as it easy to e.g. convert between commonly used PKCS#8 PEM encoded EC private keys and ECKEY objects, and because just a BIGNUM would not be sufficient.

It is possible to use ECKEY object that does not have public key field filled in for ECDSA signing. Likewise, certain functions (most notably verify operation, where private key usually is not accessible) can be used with ECKEY that does not private key filled in (i.e., it is NULL).


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.