21 void encrypt_n(
const uint8_t in[], uint8_t out[],
size_t blocks)
const override;
22 void decrypt_n(
const uint8_t in[], uint8_t out[],
size_t blocks)
const override;
24 void clear()
override;
25 std::string
provider()
const override;
27 std::string
name()
const override {
return "Serpent"; }
29 std::unique_ptr<BlockCipher>
new_object()
const override {
return std::make_unique<Serpent>(); }
36#if defined(BOTAN_HAS_SERPENT_SIMD)
37 void simd_encrypt_4(
const uint8_t in[16 * 4], uint8_t out[16 * 4])
const;
38 void simd_decrypt_4(
const uint8_t in[16 * 4], uint8_t out[16 * 4])
const;
41#if defined(BOTAN_HAS_SERPENT_AVX2)
42 void avx2_encrypt_8(
const uint8_t in[16 * 8], uint8_t out[16 * 8])
const;
43 void avx2_decrypt_8(
const uint8_t in[16 * 8], uint8_t out[16 * 8])
const;
46#if defined(BOTAN_HAS_SERPENT_AVX512)
47 void avx512_encrypt_16(
const uint8_t in[16 * 16], uint8_t out[16 * 16])
const;
48 void avx512_decrypt_16(
const uint8_t in[16 * 16], uint8_t out[16 * 16])
const;
51 void key_schedule(std::span<const uint8_t> key)
override;