Andrew Boyson / crypto

Dependents:   oldheating gps motorhome heating

Committer:
andrewboyson
Date:
Tue Oct 15 07:26:15 2019 +0000
Revision:
19:f22327e8be7b
Pulled AES128_CBC_SHA1 into its own routines to keep it apart from future work.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
andrewboyson 19:f22327e8be7b 1 #pragma once
andrewboyson 19:f22327e8be7b 2
andrewboyson 19:f22327e8be7b 3 #include <stdint.h>
andrewboyson 19:f22327e8be7b 4
andrewboyson 19:f22327e8be7b 5 #define AES128CBC_BLOCK_SIZE 16 //Block length in bytes AES is 128b block only
andrewboyson 19:f22327e8be7b 6
andrewboyson 19:f22327e8be7b 7 //void Aes128CbcInit (struct Aes128CbcState* ctx, const uint8_t* key, const uint8_t* iv);
andrewboyson 19:f22327e8be7b 8 //void Aes128CbcEncrypt(struct Aes128CbcState* ctx, uint8_t* buf, uint32_t length);
andrewboyson 19:f22327e8be7b 9 //void Aes128CbcDecrypt(struct Aes128CbcState* ctx, uint8_t* buf, uint32_t length);
andrewboyson 19:f22327e8be7b 10 void Aes128CbcEncrypt(const uint8_t* key, const uint8_t* iv, uint8_t* buf, uint32_t length);
andrewboyson 19:f22327e8be7b 11 void Aes128CbcDecrypt(const uint8_t* key, const uint8_t* iv, uint8_t* buf, uint32_t length);