aboutsummaryrefslogtreecommitdiffstats
path: root/checks/pk_bench.cpp
diff options
context:
space:
mode:
authorlloyd <[email protected]>2009-09-08 23:59:48 +0000
committerlloyd <[email protected]>2009-09-08 23:59:48 +0000
commit91c7165b698e34c9bbdbcaafe1dd28459fc8c804 (patch)
treedbe6b0152dbd0e035eebefdf8c98497adec2816d /checks/pk_bench.cpp
parent166e979eebe6e3f136df4deba626b584e1d735ae (diff)
parentabcfd1cf4b351f856c2df11ed1cd972a3a5155a9 (diff)
propagate from branch 'net.randombit.botan' (head 5cadcc57872bef55226579df57349fe09a93d1f5)
to branch 'net.randombit.botan.c++0x' (head d1747f0394aa4442e5b32b9102b830e1a86f0e5a)
Diffstat (limited to 'checks/pk_bench.cpp')
-rw-r--r--checks/pk_bench.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/checks/pk_bench.cpp b/checks/pk_bench.cpp
index fcc0a0f13..f99a13a93 100644
--- a/checks/pk_bench.cpp
+++ b/checks/pk_bench.cpp
@@ -191,12 +191,12 @@ void benchmark_rsa(RandomNumberGenerator& rng,
while(verify_timer.seconds() < seconds ||
sig_timer.seconds() < seconds)
{
- std::auto_ptr<PK_Encryptor> enc(get_pk_encryptor(key, enc_padding));
- std::auto_ptr<PK_Decryptor> dec(get_pk_decryptor(key, enc_padding));
+ std::unique_ptr<PK_Encryptor> enc(get_pk_encryptor(key, enc_padding));
+ std::unique_ptr<PK_Decryptor> dec(get_pk_decryptor(key, enc_padding));
benchmark_enc_dec(*enc, *dec, enc_timer, dec_timer, rng, 10000, seconds);
- std::auto_ptr<PK_Signer> sig(get_pk_signer(key, sig_padding));
- std::auto_ptr<PK_Verifier> ver(get_pk_verifier(key, sig_padding));
+ std::unique_ptr<PK_Signer> sig(get_pk_signer(key, sig_padding));
+ std::unique_ptr<PK_Verifier> ver(get_pk_verifier(key, sig_padding));
benchmark_sig_ver(*ver, *sig, verify_timer,
sig_timer, rng, 10000, seconds);
}
@@ -246,8 +246,8 @@ void benchmark_rw(RandomNumberGenerator& rng,
RW_PrivateKey key(rng, keylen);
keygen_timer.stop();
- std::auto_ptr<PK_Signer> sig(get_pk_signer(key, padding));
- std::auto_ptr<PK_Verifier> ver(get_pk_verifier(key, padding));
+ std::unique_ptr<PK_Signer> sig(get_pk_signer(key, padding));
+ std::unique_ptr<PK_Verifier> ver(get_pk_verifier(key, padding));
benchmark_sig_ver(*ver, *sig, verify_timer, sig_timer, rng, 10000, seconds);
}
@@ -300,8 +300,8 @@ void benchmark_ecdsa(RandomNumberGenerator& rng,
ECDSA_PrivateKey key(rng, params);
keygen_timer.stop();
- std::auto_ptr<PK_Signer> sig(get_pk_signer(key, padding));
- std::auto_ptr<PK_Verifier> ver(get_pk_verifier(key, padding));
+ std::unique_ptr<PK_Signer> sig(get_pk_signer(key, padding));
+ std::unique_ptr<PK_Verifier> ver(get_pk_verifier(key, padding));
benchmark_sig_ver(*ver, *sig, verify_timer,
sig_timer, rng, 1000, seconds);
@@ -416,8 +416,8 @@ void benchmark_dsa_nr(RandomNumberGenerator& rng,
PRIV_KEY_TYPE key(rng, group);
keygen_timer.stop();
- std::auto_ptr<PK_Signer> sig(get_pk_signer(key, padding));
- std::auto_ptr<PK_Verifier> ver(get_pk_verifier(key, padding));
+ std::unique_ptr<PK_Signer> sig(get_pk_signer(key, padding));
+ std::unique_ptr<PK_Verifier> ver(get_pk_verifier(key, padding));
benchmark_sig_ver(*ver, *sig, verify_timer,
sig_timer, rng, 1000, seconds);
@@ -586,8 +586,8 @@ void benchmark_elg(RandomNumberGenerator& rng,
ElGamal_PrivateKey key(rng, group);
keygen_timer.stop();
- std::auto_ptr<PK_Decryptor> dec(get_pk_decryptor(key, padding));
- std::auto_ptr<PK_Encryptor> enc(get_pk_encryptor(key, padding));
+ std::unique_ptr<PK_Decryptor> dec(get_pk_decryptor(key, padding));
+ std::unique_ptr<PK_Encryptor> enc(get_pk_encryptor(key, padding));
benchmark_enc_dec(*enc, *dec, enc_timer, dec_timer, rng, 1000, seconds);
}