aboutsummaryrefslogtreecommitdiffstats
path: root/src/s2k/pbkdf1/pbkdf1.cpp
diff options
context:
space:
mode:
authorlloyd <[email protected]>2010-02-01 16:29:38 +0000
committerlloyd <[email protected]>2010-02-01 16:29:38 +0000
commit454e45b7c4fece11a7f43ffa412148b4a274c90f (patch)
tree5ae87c2104fba534548e59fa477d6a5f2f5a5e29 /src/s2k/pbkdf1/pbkdf1.cpp
parentae6a404ec14cc3c86a96cd3e5c67c9c23be38147 (diff)
Modify the S2K interface. Instead of being stateful in terms of the salt
and iteration count, force it to be passed to each call to derive_key. So remove current_salt, set_iterations, new_random_salt, and change_salt functions from S2K interface. Update examples and test application to match. While I was in there, change the passhash example to use 64 bit salts and 128 bit PBKDF2 outputs.
Diffstat (limited to 'src/s2k/pbkdf1/pbkdf1.cpp')
-rw-r--r--src/s2k/pbkdf1/pbkdf1.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/s2k/pbkdf1/pbkdf1.cpp b/src/s2k/pbkdf1/pbkdf1.cpp
index fcc5b9a97..8e521e988 100644
--- a/src/s2k/pbkdf1/pbkdf1.cpp
+++ b/src/s2k/pbkdf1/pbkdf1.cpp
@@ -12,10 +12,10 @@ namespace Botan {
/*
* Return a PKCS#5 PBKDF1 derived key
*/
-OctetString PKCS5_PBKDF1::derive(u32bit key_len,
- const std::string& passphrase,
- const byte salt[], u32bit salt_size,
- u32bit iterations) const
+OctetString PKCS5_PBKDF1::derive_key(u32bit key_len,
+ const std::string& passphrase,
+ const byte salt[], u32bit salt_size,
+ u32bit iterations) const
{
if(iterations == 0)
throw Invalid_Argument("PKCS5_PBKDF1: Invalid iteration count");