10#include <botan/internal/scan_name.h>
12#if defined(BOTAN_HAS_SHAKE_XOF)
13 #include <botan/internal/shake_xof.h>
16#include <botan/exceptn.h>
17#include <botan/internal/fmt.h>
22std::unique_ptr<XOF>
XOF::create(std::string_view algo_spec, std::string_view provider) {
29#if defined(BOTAN_HAS_SHAKE_XOF)
31 return std::make_unique<SHAKE_128_XOF>();
34 return std::make_unique<SHAKE_256_XOF>();
58void XOF::start(std::span<const uint8_t> salt, std::span<const uint8_t> key) {
59 if(!
key_spec().valid_keylength(key.size())) {
71void XOF::start_msg(std::span<const uint8_t> salt, std::span<const uint8_t> key) {
const std::string & algo_name() const
static std::unique_ptr< XOF > create_or_throw(std::string_view algo_spec, std::string_view provider="")
virtual std::string provider() const
virtual bool valid_salt_length(size_t salt_len) const
virtual Key_Length_Specification key_spec() const
static std::unique_ptr< XOF > create(std::string_view algo_spec, std::string_view provider="")
virtual std::string name() const =0
void start(std::span< const uint8_t > salt={}, std::span< const uint8_t > key={})
static std::vector< std::string > providers(std::string_view algo_spec)
std::string fmt(std::string_view format, const T &... args)
std::vector< std::string > probe_providers_of(std::string_view algo_spec, const std::vector< std::string > &possible={"base"})