summaryrefslogtreecommitdiff
path: root/src/util/test_helper_rsa.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-11-23 21:10:55 +0100
committerChristian Grothoff <christian@grothoff.org>2020-11-23 21:10:55 +0100
commitd5656ec46e47d49d16b21b5cbc1c34caf5ea4b83 (patch)
treed2c6cecb321e6468ba4ce97f51f4cfddda1769c7 /src/util/test_helper_rsa.c
parent77dbb8327618ada8fd112209e54a7bf05d2958f0 (diff)
downloadexchange-d5656ec46e47d49d16b21b5cbc1c34caf5ea4b83.tar.gz
exchange-d5656ec46e47d49d16b21b5cbc1c34caf5ea4b83.tar.bz2
exchange-d5656ec46e47d49d16b21b5cbc1c34caf5ea4b83.zip
finish helper test cases
Diffstat (limited to 'src/util/test_helper_rsa.c')
-rw-r--r--src/util/test_helper_rsa.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/util/test_helper_rsa.c b/src/util/test_helper_rsa.c
index 3c7ae443b..f291f27e4 100644
--- a/src/util/test_helper_rsa.c
+++ b/src/util/test_helper_rsa.c
@@ -31,12 +31,12 @@
/**
* How many random key revocations should we test?
*/
-#define NUM_REVOKES 10
+#define NUM_REVOKES 3
/**
* How many iterations of the successful signing test should we run?
*/
-#define NUM_SIGN_TESTS 100
+#define NUM_SIGN_TESTS 5
/**
@@ -101,6 +101,9 @@ static struct KeyData keys[MAX_KEYS];
* zero if the key has been revoked or purged
* @param h_denom_pub hash of the @a denom_pub that is available (or was purged)
* @param denom_pub the public key itself, NULL if the key was revoked or purged
+ * @param sm_pub public key of the security module, NULL if the key was revoked or purged
+ * @param sm_sig signature from the security module, NULL if the key was revoked or purged
+ * The signature was already verified against @a sm_pub.
*/
static void
key_cb (void *cls,
@@ -108,8 +111,12 @@ key_cb (void *cls,
struct GNUNET_TIME_Absolute start_time,
struct GNUNET_TIME_Relative validity_duration,
const struct GNUNET_HashCode *h_denom_pub,
- const struct TALER_DenominationPublicKey *denom_pub)
+ const struct TALER_DenominationPublicKey *denom_pub,
+ const struct TALER_SecurityModulePublicKeyP *sm_pub,
+ const struct TALER_SecurityModuleSignatureP *sm_sig)
{
+ (void) sm_pub;
+ (void) sm_sig;
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
"Key notification about key %s in `%s'\n",
GNUNET_h2s (h_denom_pub),
@@ -373,7 +380,6 @@ perf_signing (struct TALER_CRYPTO_DenominationHelper *dh)
{
struct TALER_DenominationSignature ds;
enum TALER_ErrorCode ec;
- bool success = false;
struct GNUNET_HashCode m_hash;
struct GNUNET_CRYPTO_RsaBlindingKeySecret bks;
struct GNUNET_TIME_Relative duration;