aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/hash/hash.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/hash/hash.cpp')
-rw-r--r--src/lib/hash/hash.cpp21
1 files changed, 4 insertions, 17 deletions
diff --git a/src/lib/hash/hash.cpp b/src/lib/hash/hash.cpp
index 63218006c..2293059ca 100644
--- a/src/lib/hash/hash.cpp
+++ b/src/lib/hash/hash.cpp
@@ -73,10 +73,6 @@
#include <botan/sm3.h>
#endif
-#if defined(BOTAN_HAS_TIGER)
- #include <botan/tiger.h>
-#endif
-
#if defined(BOTAN_HAS_WHIRLPOOL)
#include <botan/whrlpool.h>
#endif
@@ -228,15 +224,6 @@ std::unique_ptr<HashFunction> HashFunction::create(const std::string& algo_spec,
const SCAN_Name req(algo_spec);
-#if defined(BOTAN_HAS_TIGER)
- if(req.algo_name() == "Tiger")
- {
- return std::unique_ptr<HashFunction>(
- new Tiger(req.arg_as_integer(0, 24),
- req.arg_as_integer(1, 3)));
- }
-#endif
-
#if defined(BOTAN_HAS_SKEIN_512)
if(req.algo_name() == "Skein-512")
{
@@ -270,13 +257,13 @@ std::unique_ptr<HashFunction> HashFunction::create(const std::string& algo_spec,
#endif
#if defined(BOTAN_HAS_SHAKE)
- if(req.algo_name() == "SHAKE-128")
+ if(req.algo_name() == "SHAKE-128" && req.arg_count() == 1)
{
- return std::unique_ptr<HashFunction>(new SHAKE_128(req.arg_as_integer(0, 128)));
+ return std::unique_ptr<HashFunction>(new SHAKE_128(req.arg_as_integer(0)));
}
- if(req.algo_name() == "SHAKE-256")
+ if(req.algo_name() == "SHAKE-256" && req.arg_count() == 1)
{
- return std::unique_ptr<HashFunction>(new SHAKE_256(req.arg_as_integer(0, 256)));
+ return std::unique_ptr<HashFunction>(new SHAKE_256(req.arg_as_integer(0)));
}
#endif