aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pbkdf/pbkdf2
diff options
context:
space:
mode:
authorlloyd <[email protected]>2015-02-18 04:51:17 +0000
committerlloyd <[email protected]>2015-02-18 04:51:17 +0000
commit888aed4ec2f08684a9707c1251f27285942578c5 (patch)
tree4c78c5ca5a31b217f407c3adbd138a227181b1c5 /src/lib/pbkdf/pbkdf2
parent88285f51ba4fd5bc1a1cc06b0760b3926046f29b (diff)
Convert HKDF to the normal KDF interface
Diffstat (limited to 'src/lib/pbkdf/pbkdf2')
-rw-r--r--src/lib/pbkdf/pbkdf2/pbkdf2.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/lib/pbkdf/pbkdf2/pbkdf2.cpp b/src/lib/pbkdf/pbkdf2/pbkdf2.cpp
index 0ff412bc5..88360e6a2 100644
--- a/src/lib/pbkdf/pbkdf2/pbkdf2.cpp
+++ b/src/lib/pbkdf/pbkdf2/pbkdf2.cpp
@@ -8,7 +8,6 @@
#include <botan/internal/pbkdf_utils.h>
#include <botan/pbkdf2.h>
#include <botan/get_byte.h>
-#include <botan/hmac.h>
#include <botan/internal/xor_buf.h>
#include <botan/internal/rounding.h>
@@ -21,8 +20,8 @@ PKCS5_PBKDF2* PKCS5_PBKDF2::make(const Spec& spec)
if(auto mac = make_a<MessageAuthenticationCode>(spec.arg(0)))
return new PKCS5_PBKDF2(mac);
- if(auto hash = make_a<HashFunction>(spec.arg(0)))
- return new PKCS5_PBKDF2(new HMAC(hash));
+ if(auto mac = make_a<MessageAuthenticationCode>("HMAC(" + spec.arg(0) + ")"))
+ return new PKCS5_PBKDF2(mac);
return nullptr;
}