Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add EVP_PKEY_RSA_PSS decode support. (aws#140)
* Define RSA_PSS_SALTLEN_DIGEST macro. (aws#85) * Define RSA_PSS_SALTLEN_DIGEST macro. * Replace '-1' with RSA_PSS_SALTLEN_DIGEST. * Add EVP_PKEY_RSA_PSS ameth. (aws#86) * Add EVP_PKEY_RSA_PSS ameth. * Add test to verify SubjectPublicKeyInfo decode. * Add EVP_PKEY_RSA_PSS pmeth. (aws#87) * Add EVP_PKEY_RSA_PSS ameth. * Add test to verify SubjectPublicKeyInfo decode. * Add EVP_PKEY_RSA_PSS pmeth. * Import RSA_pkey_ctx_ctrl -- OpenSSL 1.1.1@e5e04ee. * Support pad mode get/set for PSS keys. OpenSSL 1.1.1@a300c72. * Fix TODO comment. * Update crypto/fipsmodule/rsa/rsa.c Co-authored-by: torben-hansen <[email protected]> * Define new error code -- RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE. * Move RSA ctrl func from rsa.h to evp/internal.h * Remove RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE. * Add '||' * Remove imports. Co-authored-by: torben-hansen <[email protected]> * Add RSASSA-PSS-params decode. (aws#89) * Add EVP_PKEY_RSA_PSS ameth. * Add test to verify SubjectPublicKeyInfo decode. * Add EVP_PKEY_RSA_PSS pmeth. * Import RSA_pkey_ctx_ctrl -- OpenSSL 1.1.1@e5e04ee. * Support pad mode get/set for PSS keys. OpenSSL 1.1.1@a300c72. * Fix TODO comment. * Add RSASSA-PSS-params decode. * Remove trailer field related TODO. * Fix leaked mem. * Remove unsupported sha oid. * Revert "Remove unsupported sha oid." This reverts commit be955ce. * Move rsassa_pss from rsa.h to rsassa_pss.h. * Fix merge conflict. * Correct error prefix. * Remove unused import. * Improve comment. * Use JDK11 generated DER-encoded RSASSA-PSS-params for test. * Remove unused comment. * Update crypto/rsa_extra/rsassa_pss.h Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss.h Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss_asn1.c Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss_asn1.c Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss_asn1.c Co-authored-by: torben-hansen <[email protected]> * Apply suggestions from code review Co-authored-by: torben-hansen <[email protected]> * Enhance code comments. * Define tag value index macros. * Condense code. * Update crypto/rsa_extra/rsassa_pss_asn1_test.cc Co-authored-by: torben-hansen <[email protected]> * Check EVP_PKEY_assign return value. * Check NID_undef value. * Correct comments. * Add more tests. * Add more tests on trailer field and salt length. * Rename rsassa_pss.h to internal.h. Co-authored-by: torben-hansen <[email protected]> * Validate pss params. (aws#90) * Add EVP_PKEY_RSA_PSS ameth. * Add test to verify SubjectPublicKeyInfo decode. * Add EVP_PKEY_RSA_PSS pmeth. * Import RSA_pkey_ctx_ctrl -- OpenSSL 1.1.1@e5e04ee. * Support pad mode get/set for PSS keys. OpenSSL 1.1.1@a300c72. * Fix TODO comment. * Add RSASSA-PSS-params decode. * Remove trailer field related TODO. * Fix leaked mem. * Remove unsupported sha oid. * Revert "Remove unsupported sha oid." This reverts commit be955ce. * Check PSS parameters restrictions. * Move rsassa_pss from rsa.h to rsassa_pss.h. * Fix merge conflict. * Move rsassapss conversion to rsassa_pss_asn1.c. * Correct error prefix. * Remove unused import. * Modify comment. * Improve comment. * Rename some functions. * Add more tests. * Add more tests. * Resolve TODO: fix X509Test.TestRsaSsaPss. * Use JDK11 generated DER-encoded RSASSA-PSS-params for test. * Disable rsassaPss encrypt and decrypt. * Remove unused comment. * Update crypto/rsa_extra/rsassa_pss.h Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss.h Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss_asn1.c Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss_asn1.c Co-authored-by: torben-hansen <[email protected]> * Update crypto/rsa_extra/rsassa_pss_asn1.c Co-authored-by: torben-hansen <[email protected]> * Apply suggestions from code review Co-authored-by: torben-hansen <[email protected]> * Enhance code comments. * Define tag value index macros. * Condense code. * Update crypto/rsa_extra/rsassa_pss_asn1_test.cc Co-authored-by: torben-hansen <[email protected]> * Check EVP_PKEY_assign return value. * Check NID_undef value. * Correct comments. * Add more tests. * Add more tests on trailer field and salt length. * Rename rsassa_pss.h to internal.h. * Removed unused test data. * Modify comments. * Explicitly check NULL. * Change method comment. * Address error code comment. * Apply suggestions from code review Co-authored-by: dkostic <[email protected]> Co-authored-by: torben-hansen <[email protected]> * Return EVP_PKEY_assign_* value. * Fix incorrect error code. * Adjust comment. * Define macro for default value of salt len and trailer field. * Fix max salt len. * Add more comments. * Check inputs are not NULL. * Remove saltlen == 0 check in pss_saltlen_create. * Add ctx->pkey NULL check in pkey_pss_init. Co-authored-by: torben-hansen <[email protected]> Co-authored-by: dkostic <[email protected]> * Avoid double free. Co-authored-by: torben-hansen <[email protected]> Co-authored-by: dkostic <[email protected]>
- Loading branch information