
C语言实现AES128/192/256加密解密,已测试通过
5星
- 浏览量: 0
- 大小:None
- 文件类型:None
简介:
本项目提供了一个用C语言编写的库,实现了AES-128、AES-192和AES-256算法的加密与解密功能,并经过全面测试验证。
本人实测可以使用基于C的AES算法代码,希望能帮到有需要的人。以下是相关模式调用的函数:
- `void AES_init_ctx(struct AES_ctx* ctx, const uint8_t* key);`
- `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);`
- `void AES_ECB_encrypt(const struct AES_ctx* ctx, uint8_t* buf);`
- `void AES_ECB_decrypt(const struct AES_ctx* ctx, uint8_t* buf);`
- `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_CTR_xcrypt_buffer(struct AES_ctx* ctx, uint8_t* buf, uint32_t length);`
全部评论 (0)
还没有任何评论哟~


