From 2b7e085deac956660827f23e339eae797a3326ea Mon Sep 17 00:00:00 2001 From: Martin Willi Date: Thu, 13 Aug 2009 15:39:29 +0200 Subject: updated pubkey_speed test to use pem plugin --- scripts/pubkey_speed.c | 8 +------- scripts/pubkey_speed.sh | 4 ++-- 2 files changed, 3 insertions(+), 9 deletions(-) (limited to 'scripts') diff --git a/scripts/pubkey_speed.c b/scripts/pubkey_speed.c index 86a4e105b..120ca858c 100644 --- a/scripts/pubkey_speed.c +++ b/scripts/pubkey_speed.c @@ -4,7 +4,6 @@ #include #include #include -#include void start_timing(struct timespec *start) { @@ -70,14 +69,9 @@ int main(int argc, char *argv[]) pos += read; keydata.len += read; } - if (pem_to_bin(&keydata, chunk_empty, NULL) != SUCCESS) - { - printf("converting PEM private key failed.\n"); - exit(1); - } private = lib->creds->create(lib->creds, CRED_PRIVATE_KEY, type, - BUILD_BLOB_ASN1_DER, keydata, BUILD_END); + BUILD_BLOB_PEM, keydata, BUILD_END); if (!private) { printf("parsing private key failed.\n"); diff --git a/scripts/pubkey_speed.sh b/scripts/pubkey_speed.sh index cbdfde5be..307677403 100755 --- a/scripts/pubkey_speed.sh +++ b/scripts/pubkey_speed.sh @@ -30,7 +30,7 @@ function ecdsatestall { ecdsatest secp521r1 "$1" 500 } -rsatestall "gmp gcrypt" -rsatestall "gcrypt" +rsatestall "gmp gcrypt pem" +rsatestall "gcrypt pem" rsatestall "openssl" ecdsatestall "openssl" -- cgit v1.2.3