pkcs11: Optionally hash data for PKCS#1 v1.5 RSA signatures in software
authorTobias Brunner <tobias@strongswan.org>
Mon, 4 May 2020 07:45:39 +0000 (09:45 +0200)
committerTobias Brunner <tobias@strongswan.org>
Thu, 7 May 2020 07:11:19 +0000 (09:11 +0200)
commitb6fcdc71a6e3cbb29a68d412967017c4c9937e5a
treed40171c9e4f84bb5bf8caaba68dfbf3e38dea06c
parentb3e7b79cc5b9387e3d22f9ca995119e64c9fc9a0
pkcs11: Optionally hash data for PKCS#1 v1.5 RSA signatures in software

If cards/libraries don't support signature mechanisms with hashing, we fall
back to do it ourselves in software and pass the PKCS#1 digestInfo ASN.1
structure to sign via CKM_RSA_PKCS mechanism.

Closes strongswan/strongswan#168.
src/libstrongswan/plugins/pkcs11/pkcs11_private_key.c
src/libstrongswan/plugins/pkcs11/pkcs11_private_key.h
src/libstrongswan/plugins/pkcs11/pkcs11_public_key.c