Rename concept Encryptor --> BlockEncryptor.
This commit is contained in:
1 parent
d918e998d1
commit
894f41fa57
4 files changed
+14
-14
No files matched your search
@@ -5,7 +5,7 @@
|
||||
#include <type_traits>
|
||||
|
||||
#include "BlockKey.hpp"
|
||||
#include "Encryptor.hpp"
|
||||
#include "BlockEncryptor.hpp"
|
||||
#include "BlockDecryptor.hpp"
|
||||
|
||||
namespace Chaos::Cipher::Block
|
||||
@@ -26,7 +26,7 @@ concept BlockCipher = requires
|
||||
typename std::integral_constant<decltype(T::KeySize), T::KeySize>;
|
||||
|
||||
requires BlockKey<typename T::Key>;
|
||||
requires Encryptor<typename T::Encryptor>;
|
||||
requires BlockEncryptor<typename T::Encryptor>;
|
||||
requires BlockDecryptor<typename T::Decryptor>;
|
||||
};
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#ifndef CHAOS_CIPHER_BLOCK_ENCRYPTOR_HPP
|
||||
#define CHAOS_CIPHER_BLOCK_ENCRYPTOR_HPP
|
||||
#ifndef CHAOS_CIPHER_BLOCK_BLOCKENCRYPTOR_HPP
|
||||
#define CHAOS_CIPHER_BLOCK_BLOCKENCRYPTOR_HPP
|
||||
|
||||
#include <concepts>
|
||||
#include <cstdint>
|
||||
@@ -9,10 +9,10 @@ namespace Chaos::Cipher::Block
|
||||
{
|
||||
|
||||
template<typename T>
|
||||
concept Encryptor = requires(const T constEncryptor,
|
||||
typename T::Block block,
|
||||
uint8_t * outBegin, uint8_t * outEnd,
|
||||
uint8_t * inBegin, uint8_t * inEnd)
|
||||
concept BlockEncryptor = requires(const T constEncryptor,
|
||||
typename T::Block block,
|
||||
uint8_t * outBegin, uint8_t * outEnd,
|
||||
uint8_t * inBegin, uint8_t * inEnd)
|
||||
{
|
||||
typename T::Block;
|
||||
typename T::Key;
|
||||
@@ -31,4 +31,4 @@ concept Encryptor = requires(const T constEncryptor,
|
||||
|
||||
} // namespace Chaos::Cipher::Block
|
||||
|
||||
#endif // CHAOS_CIPHER_BLOCK_ENCRYPTOR_HPP
|
||||
#endif // CHAOS_CIPHER_BLOCK_BLOCKENCRYPTOR_HPP
|
||||
@@ -11,7 +11,7 @@
|
||||
#include "Service/SeArray.hpp"
|
||||
|
||||
#include "Cipher/Block/BlockKey.hpp"
|
||||
#include "Cipher/Block/Encryptor.hpp"
|
||||
#include "Cipher/Block/BlockEncryptor.hpp"
|
||||
#include "Cipher/Block/BlockDecryptor.hpp"
|
||||
#include "Cipher/Block/BlockCipher.hpp"
|
||||
|
||||
@@ -283,7 +283,7 @@ public:
|
||||
Inner_::KeySchedule Schedule_;
|
||||
};
|
||||
|
||||
static_assert(Chaos::Cipher::Block::Encryptor<Encryptor>);
|
||||
static_assert(Chaos::Cipher::Block::BlockEncryptor<Encryptor>);
|
||||
|
||||
class Decryptor
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user