|
Turnstone Operating System
|
AES encryption and decryption functions. More...
Macros | |
| #define | GET_UINT32_LE(n, b, i) |
| #define | PUT_UINT32_LE(n, b, i) |
| #define | AES_FROUND(X0, X1, X2, X3, Y0, Y1, Y2, Y3) |
| #define | AES_RROUND(X0, X1, X2, X3, Y0, Y1, Y2, Y3) |
| #define | ROTL8(x) |
| #define | XTIME(x) |
| #define | MUL(x, y) |
| #define | MIX(x, y) |
| #define | CPY128 |
Functions | |
| MODULE ("turnstone.lib.crypto") | |
| int32_t | aes_set_encryption_key (aes_context_t *ctx, const uint8_t *key, uint32_t keysize) |
| int32_t | aes_set_decryption_key (aes_context_t *ctx, const uint8_t *key, uint32_t keysize) |
| void | aes_init_keygen_tables (void) |
| int32_t | aes_setkey (aes_context_t *ctx, int32_t mode, const uint8_t *key, uint32_t keysize) |
| int32_t | aes_cipher (aes_context_t *ctx, const uint8_t input[16], uint8_t output[16]) |
Variables | |
| static int32_t | aes_tables_inited = 0 |
| static uint8_t | AES_FSb [256] = {0} |
| static uint32_t | AES_FT0 [256] = {0} |
| static uint32_t | AES_FT1 [256] = {0} |
| static uint32_t | AES_FT2 [256] = {0} |
| static uint32_t | AES_FT3 [256] = {0} |
| static uint8_t | AES_RSb [256] = {0} |
| static uint32_t | AES_RT0 [256] = {0} |
| static uint32_t | AES_RT1 [256] = {0} |
| static uint32_t | AES_RT2 [256] = {0} |
| static uint32_t | AES_RT3 [256] = {0} |
| static uint32_t | AES_RCON [10] = {0} |
AES encryption and decryption functions.
This work is licensed under TURNSTONE OS Public License. Please read and understand latest version of Licence.
| #define AES_FROUND | ( | X0, | |
| X1, | |||
| X2, | |||
| X3, | |||
| Y0, | |||
| Y1, | |||
| Y2, | |||
| Y3 ) |
| #define AES_RROUND | ( | X0, | |
| X1, | |||
| X2, | |||
| X3, | |||
| Y0, | |||
| Y1, | |||
| Y2, | |||
| Y3 ) |
| #define CPY128 |
| #define GET_UINT32_LE | ( | n, | |
| b, | |||
| i ) |
| #define MIX | ( | x, | |
| y ) |
| #define MUL | ( | x, | |
| y ) |
| #define PUT_UINT32_LE | ( | n, | |
| b, | |||
| i ) |
| #define ROTL8 | ( | x | ) |
| #define XTIME | ( | x | ) |