mirror of
https://github.com/kokke/tiny-AES-c
synced 2024-11-22 05:21:52 +03:00
protect Iv and AES functions if CFB enabled
This commit is contained in:
parent
a71d856ee9
commit
43ee63f00a
4
aes.h
4
aes.h
@ -47,13 +47,13 @@
|
||||
struct AES_ctx
|
||||
{
|
||||
uint8_t RoundKey[AES_keyExpSize];
|
||||
#if (defined(CBC) && (CBC == 1)) || (defined(CTR) && (CTR == 1))
|
||||
#if (defined(CBC) && (CBC == 1)) || (defined(CTR) && (CTR == 1)) || (defined(CFB) && (CFB == 1))
|
||||
uint8_t Iv[AES_BLOCKLEN];
|
||||
#endif
|
||||
};
|
||||
|
||||
void AES_init_ctx(struct AES_ctx* ctx, const uint8_t* key);
|
||||
#if (defined(CBC) && (CBC == 1)) || (defined(CTR) && (CTR == 1))
|
||||
#if (defined(CBC) && (CBC == 1)) || (defined(CTR) && (CTR == 1)) || (defined(CFB) && (CFB == 1))
|
||||
void AES_init_ctx_iv(struct AES_ctx* ctx, const uint8_t* key, const uint8_t* iv);
|
||||
void AES_ctx_set_iv(struct AES_ctx* ctx, const uint8_t* iv);
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user