diff options
author | lloyd <[email protected]> | 2008-06-27 20:21:45 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2008-06-27 20:21:45 +0000 |
commit | 3d0a9fd636e5ca91fcf8f5c0e13dcf659940b564 (patch) | |
tree | 4ce02817eac4c55b27cc75106adce227b4461220 /doc/examples/rsa_dec.cpp | |
parent | 964dbc067992211e7d566c881de2c7330f46bef2 (diff) |
Update more of the examples
Diffstat (limited to 'doc/examples/rsa_dec.cpp')
-rw-r--r-- | doc/examples/rsa_dec.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/doc/examples/rsa_dec.cpp b/doc/examples/rsa_dec.cpp index 6f71e2831..910d07adf 100644 --- a/doc/examples/rsa_dec.cpp +++ b/doc/examples/rsa_dec.cpp @@ -32,8 +32,10 @@ int main(int argc, char* argv[]) return 1; } - try { - std::auto_ptr<PKCS8_PrivateKey> key(PKCS8::load_key(argv[1], argv[3])); + try + { + std::auto_ptr<RandomNumberGenerator> rng(make_rng()); + std::auto_ptr<PKCS8_PrivateKey> key(PKCS8::load_key(argv[1], *rng, argv[3])); RSA_PrivateKey* rsakey = dynamic_cast<RSA_PrivateKey*>(key.get()); if(!rsakey) { |