diff options
author | kokke <spam@rowdy.dk> | 2021-01-06 02:35:05 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-06 02:35:05 +0100 |
commit | c3b7532b6deb507c40c0c53cc3c8b49a50766d9b (patch) | |
tree | c4d7196d5d175c41bf104bc13fd868bbaa85faf0 /aes.h | |
parent | Update README.md (diff) | |
parent | use size_t for buffer size and its indexes (diff) | |
download | tiny-AES-c-c3b7532b6deb507c40c0c53cc3c8b49a50766d9b.tar tiny-AES-c-c3b7532b6deb507c40c0c53cc3c8b49a50766d9b.tar.gz tiny-AES-c-c3b7532b6deb507c40c0c53cc3c8b49a50766d9b.tar.bz2 tiny-AES-c-c3b7532b6deb507c40c0c53cc3c8b49a50766d9b.tar.lz tiny-AES-c-c3b7532b6deb507c40c0c53cc3c8b49a50766d9b.tar.xz tiny-AES-c-c3b7532b6deb507c40c0c53cc3c8b49a50766d9b.tar.zst tiny-AES-c-c3b7532b6deb507c40c0c53cc3c8b49a50766d9b.zip |
Diffstat (limited to 'aes.h')
-rw-r--r-- | aes.h | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -69,8 +69,8 @@ void AES_ECB_decrypt(const struct AES_ctx* ctx, uint8_t* buf); // Suggest https://en.wikipedia.org/wiki/Padding_(cryptography)#PKCS7 for padding scheme // NOTES: you need to set IV in ctx via AES_init_ctx_iv() or AES_ctx_set_iv() // no IV should ever be reused with the same key -void AES_CBC_encrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, uint32_t length); -void AES_CBC_decrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, uint32_t length); +void AES_CBC_encrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, size_t length); +void AES_CBC_decrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, size_t length); #endif // #if defined(CBC) && (CBC == 1) @@ -82,7 +82,7 @@ void AES_CBC_decrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, uint32_t length); // Suggesting https://en.wikipedia.org/wiki/Padding_(cryptography)#PKCS7 for padding scheme // NOTES: you need to set IV in ctx with AES_init_ctx_iv() or AES_ctx_set_iv() // no IV should ever be reused with the same key -void AES_CTR_xcrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, uint32_t length); +void AES_CTR_xcrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, size_t length); #endif // #if defined(CTR) && (CTR == 1) |