aboutsummaryrefslogtreecommitdiffstats
path: root/checks
diff options
context:
space:
mode:
authorlloyd <[email protected]>2008-08-30 21:09:15 +0000
committerlloyd <[email protected]>2008-08-30 21:09:15 +0000
commit0ebbd31c3df8b5ef30c02393abfb48f0dc299e6b (patch)
tree67c49b909f0687c64611f7e5a23d4c2d9fc0d31c /checks
parent605627ccc4045c5061ef8896d902554370b4e70d (diff)
Benchmark change: Skip RSA 1536, DH 1536. Add DSA 2048/256 and 3072/256, RSA 8192, DH 8192
Diffstat (limited to 'checks')
-rw-r--r--checks/pk_bench.cpp22
1 files changed, 16 insertions, 6 deletions
diff --git a/checks/pk_bench.cpp b/checks/pk_bench.cpp
index 8bb4e791c..2a7e2a1db 100644
--- a/checks/pk_bench.cpp
+++ b/checks/pk_bench.cpp
@@ -64,7 +64,7 @@ void bench_pk(RandomNumberGenerator& rng,
if(algo == "All" || algo == "RSA")
{
- const u32bit keylen[] = { 512, 1024, 1536, 2048, 3072, 4096, 0 };
+ const u32bit keylen[] = { 512, 1024, 2048, 3072, 4096, 8192, 0 };
for(size_t j = 0; keylen[j]; j++)
{
@@ -89,13 +89,23 @@ void bench_pk(RandomNumberGenerator& rng,
if(algo == "All" || algo == "DSA")
{
- const u32bit keylen[] = { 512, 768, 1024, 0 };
+ struct dsa_groups { int psize; int qsize; };
- for(size_t j = 0; keylen[j]; j++)
+ const dsa_groups keylen[] = { { 512, 160 },
+ { 768, 160 },
+ { 1024, 160 },
+ { 2048, 256 },
+ { 3072, 256 },
+ { 0, 0 } };
+
+ for(size_t j = 0; keylen[j].psize; j++)
{
- const std::string len_str = to_string(keylen[j]);
+ const std::string len_str = to_string(keylen[j].psize);
+
+ DL_Group group(rng, DL_Group::DSA_Kosherizer,
+ keylen[j].psize, keylen[j].qsize);
- DSA_PrivateKey key(rng, "dsa/jce/" + len_str);
+ DSA_PrivateKey key(rng, group);
bench_ver(get_pk_signer(key, "EMSA1(SHA-1)"),
get_pk_verifier(key, "EMSA1(SHA-1)"),
@@ -108,7 +118,7 @@ void bench_pk(RandomNumberGenerator& rng,
if(algo == "All" || algo == "DH")
{
- const u32bit keylen[] = { 768, 1024, 1536, 2048, 3072, 4096, 0 };
+ const u32bit keylen[] = { 1024, 2048, 3072, 4096, 8192, 0 };
for(size_t j = 0; keylen[j]; j++)
{