From 47489c5567bd6f02368cc6e03c69d6c53fce8e81 Mon Sep 17 00:00:00 2001 From: sth Date: Thu, 17 Jul 2003 22:53:48 +0000 Subject: [PATCH] Added some debugging info git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@1279 c6295689-39f2-0310-b995-f0e70906c6a9 --- src/pkcs11/openssl.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/pkcs11/openssl.c b/src/pkcs11/openssl.c index 7dab09ba..7dc9e4ab 100644 --- a/src/pkcs11/openssl.c +++ b/src/pkcs11/openssl.c @@ -264,8 +264,10 @@ CK_RV sc_pkcs11_verify_data(unsigned char *pubkey, int pubkey_len, return CKR_OK; else if (res == 0) return CKR_SIGNATURE_INVALID; - else if (res != 1) + else { + debug(context, "EVP_VerifyFinal() returned %d\n", res); return CKR_GENERAL_ERROR; + } } else { RSA *rsa; @@ -298,6 +300,7 @@ CK_RV sc_pkcs11_verify_data(unsigned char *pubkey, int pubkey_len, RSA_free(rsa); if(rsa_outlen <= 0) { free(rsa_out); + debug(context, "RSA_public_decrypt() returned %d\n", rsa_outlen); return CKR_GENERAL_ERROR; }