Coverage Report

Created: 2025-04-11 06:34

/src/botan/build/include/internal/botan/internal/kuznyechik.h
Line
Count
Source (jump to first uncovered line)
1
/*
2
* Kuznyechik
3
* (C) 2012 Jack Lloyd
4
*
5
* Botan is released under the Simplified BSD License (see license.txt)
6
*/
7
8
#ifndef BOTAN_KUZNYECHIK_H_
9
#define BOTAN_KUZNYECHIK_H_
10
11
#include <botan/block_cipher.h>
12
13
namespace Botan {
14
15
/**
16
* Kuznyechik
17
*/
18
class Kuznyechik final : public Botan::Block_Cipher_Fixed_Params<16, 32> {
19
   public:
20
      void encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const override;
21
      void decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const override;
22
23
      void clear() override;
24
25
0
      std::string name() const override { return "Kuznyechik"; }
26
27
0
      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<Kuznyechik>(); }
28
29
      bool has_keying_material() const override;
30
      ~Kuznyechik() override;
31
32
   private:
33
      void key_schedule(std::span<const uint8_t> key) override;
34
      uint64_t m_rke[10][2];
35
      uint64_t m_rkd[10][2];
36
      bool m_has_keying_material;
37
};
38
39
}  // namespace Botan
40
41
#endif