10#include <botan/internal/cshake_xof.h>
12#include <botan/exceptn.h>
13#include <botan/mem_ops.h>
14#include <botan/internal/keccak_helpers.h>
15#include <botan/internal/loadstor.h>
20 m_keccak(capacity, 0b00, 2), m_function_name(std::move(function_name)), m_output_generated(false) {
32void cSHAKE_XOF::reset() {
34 m_output_generated =
false;
52 return m_function_name.size() + salt_length > 0;
55void cSHAKE_XOF::start_msg(std::span<const uint8_t> salt, std::span<const uint8_t> key) {
61void cSHAKE_XOF::add_data(std::span<const uint8_t> input) {
66void cSHAKE_XOF::generate_bytes(std::span<uint8_t> output) {
67 if(!m_output_generated) {
68 m_output_generated =
true;
#define BOTAN_ASSERT_NOMSG(expr)
#define BOTAN_STATE_CHECK(expr)
void squeeze(std::span< uint8_t > output)
Expand output data from the current Keccak state.
std::string provider() const
void absorb(std::span< const uint8_t > input)
Absorb input data into the Keccak sponge.
void finish()
Add final padding (as provided in the constructor) and permute.
std::array< uint8_t, count > output()
size_t block_size() const final
cSHAKE_XOF(size_t capacity, std::vector< uint8_t > function_name)
const std::vector< uint8_t > & function_name() const
bool valid_salt_length(size_t salt_length) const final
std::string provider() const final
size_t keccak_absorb_padded_strings_encoding(T &sink, size_t padding_mod, Ts... byte_strings)
const uint8_t * cast_char_ptr_to_uint8(const char *s)