From 2b50c7b87374c0e3a747bd754f15921b80d6563a Mon Sep 17 00:00:00 2001 From: Jack Lloyd Date: Mon, 18 Dec 2017 09:02:47 -0500 Subject: Accept ChaCha20 as a name --- src/lib/stream/stream_cipher.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/lib') diff --git a/src/lib/stream/stream_cipher.cpp b/src/lib/stream/stream_cipher.cpp index c0e75c0a8..77e68d129 100644 --- a/src/lib/stream/stream_cipher.cpp +++ b/src/lib/stream/stream_cipher.cpp @@ -64,6 +64,12 @@ std::unique_ptr StreamCipher::create(const std::string& algo_spec, if(provider.empty() || provider == "base") return std::unique_ptr(new ChaCha(req.arg_as_integer(0, 20))); } + + if(req.algo_name() == "ChaCha20") + { + if(provider.empty() || provider == "base") + return std::unique_ptr(new ChaCha(20)); + } #endif #if defined(BOTAN_HAS_SALSA20) -- cgit v1.2.3