![]() |
Signet Forge 0.1.0
C++20 Parquet library with AI-native extensions
|
DEMO |
AES-256 block cipher (FIPS-197). More...
#include <aes_core.hpp>
Public Member Functions | |
| Aes256 (const uint8_t key[KEY_SIZE]) | |
| Initialize with a 32-byte key. Performs key expansion immediately. | |
| Aes256 (const Aes256 &)=delete | |
| Aes256 & | operator= (const Aes256 &)=delete |
| Aes256 (Aes256 &&other) noexcept | |
| Aes256 & | operator= (Aes256 &&other) noexcept |
| ~Aes256 () | |
| Destructor: securely zero round keys to prevent key material leakage. | |
| void | encrypt_block (uint8_t block[BLOCK_SIZE]) const |
| Encrypt a single 16-byte block in-place (FIPS-197 Section 5.1). | |
| void | decrypt_block (uint8_t block[BLOCK_SIZE]) const |
| Decrypt a single 16-byte block in-place (FIPS-197 Section 5.3). | |
Static Public Attributes | |
| static constexpr size_t | KEY_SIZE = 32 |
| Key size in bytes (256 bits). | |
| static constexpr size_t | BLOCK_SIZE = 16 |
| Block size in bytes (128 bits). | |
| static constexpr int | NUM_ROUNDS = 14 |
| Number of AES-256 rounds. | |
AES-256 block cipher (FIPS-197).
Clean-room, table-based implementation providing correct AES-256 encrypt and decrypt for a single 128-bit block. Higher-level modes (GCM, CTR) are built on top in separate headers.
Definition at line 253 of file aes_core.hpp.
|
inlineexplicit |
Initialize with a 32-byte key. Performs key expansion immediately.
Definition at line 260 of file aes_core.hpp.
|
delete |
|
inlinenoexcept |
Definition at line 266 of file aes_core.hpp.
|
inline |
Destructor: securely zero round keys to prevent key material leakage.
Definition at line 270 of file aes_core.hpp.
|
inline |
Decrypt a single 16-byte block in-place (FIPS-197 Section 5.3).
Uses the "direct" inverse cipher: AddRoundKey(14), then 13 rounds of InvShiftRows/InvSubBytes/AddRoundKey/InvMixColumns, followed by a final round without InvMixColumns.
| block | 16-byte ciphertext block; overwritten with plaintext. |
Definition at line 328 of file aes_core.hpp.
|
inline |
Encrypt a single 16-byte block in-place (FIPS-197 Section 5.1).
Applies AddRoundKey(0), then 13 rounds of SubBytes/ShiftRows/MixColumns/ AddRoundKey, followed by a final round without MixColumns.
| block | 16-byte plaintext block; overwritten with ciphertext. |
Definition at line 280 of file aes_core.hpp.
Definition at line 267 of file aes_core.hpp.
|
staticconstexpr |
Block size in bytes (128 bits).
Definition at line 256 of file aes_core.hpp.
|
staticconstexpr |
Key size in bytes (256 bits).
Definition at line 255 of file aes_core.hpp.
|
staticconstexpr |
Number of AES-256 rounds.
Definition at line 257 of file aes_core.hpp.