aboutsummaryrefslogtreecommitdiffstats
path: root/src/engine/def_engine/lookup_hash.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/engine/def_engine/lookup_hash.cpp')
-rw-r--r--src/engine/def_engine/lookup_hash.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/engine/def_engine/lookup_hash.cpp b/src/engine/def_engine/lookup_hash.cpp
index 4ce7915d4..1d96d4f3f 100644
--- a/src/engine/def_engine/lookup_hash.cpp
+++ b/src/engine/def_engine/lookup_hash.cpp
@@ -83,6 +83,10 @@
#include <botan/par_hash.h>
#endif
+#if defined(BOTAN_HAS_COMB4P)
+ #include <botan/comb4p.h>
+#endif
+
namespace Botan {
/*
@@ -185,6 +189,17 @@ Default_Engine::find_hash(const SCAN_Name& request,
return new Whirlpool;
#endif
+#if defined(BOTAN_HAS_COMB4P)
+ if(request.algo_name() == "Comb4P" && request.arg_count() == 2)
+ {
+ const HashFunction* h1 = af.prototype_hash_function(request.arg(0));
+ const HashFunction* h2 = af.prototype_hash_function(request.arg(1));
+
+ if(h1 && h2)
+ return new Comb4P(h1->clone(), h2->clone());
+ }
+#endif
+
#if defined(BOTAN_HAS_PARALLEL_HASH)
if(request.algo_name() == "Parallel")