23 #define DUMP(s, i, buf, sz) {printf(s); \ 24 for (i = 0; i < (sz);i++) \ 25 printf("%02x ", buf[i]); \ 28 int main (
int argc,
char *argv[])
35 for (i = 0; i <
sizeof(buf);i++){
39 for (i = 0; i <
sizeof(
key);i++){
43 DUMP(
"txt: ", i, buf,
sizeof(buf));
44 DUMP(
"key: ", i, key,
sizeof(key));
51 DUMP(
"enc: ", i, buf,
sizeof(buf));
52 printf(
"tst: 8e a2 b7 ca 51 67 45 bf ea fc 49 90 4b 49 60 89\n");
#define DUMP(s, i, buf, sz)
void aes256_encrypt_ecb(aes256_context *ctx, uint8_t k[32], uint8_t buf[16])
int main(int argc, char *argv[])