diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2015-06-03 20:55:09 +0300 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2015-06-03 20:55:09 +0300 |
commit | 6b070da3e039d2ca7accae8489d8bc4a44ba652a (patch) | |
tree | 96fde3d04e1396cb5365d41991f3fc71498e964e /examples/aes128cbc_example.c | |
parent | add FIPS-style block parsing functions (diff) | |
download | aes-tools-6b070da3e039d2ca7accae8489d8bc4a44ba652a.tar.gz aes-tools-6b070da3e039d2ca7accae8489d8bc4a44ba652a.zip |
implement CBC wrappers in C
Diffstat (limited to 'examples/aes128cbc_example.c')
-rw-r--r-- | examples/aes128cbc_example.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/aes128cbc_example.c b/examples/aes128cbc_example.c index bae250b..cb5684e 100644 --- a/examples/aes128cbc_example.c +++ b/examples/aes128cbc_example.c @@ -43,7 +43,7 @@ int main() printf("\t[%d]: %s\n", i, format_aes_block128_fips_style(&key_schedule.keys[i]).str); } - cypher = aes128cbc_encrypt(plain, &key_schedule, &iv); + cypher = aes128cbc_encrypt(plain, &key_schedule, iv); printf("\n"); printf("Cypher: %s\n", format_aes_block128(&cypher).str); printf(" %s\n", format_aes_block128_fips_style(&cypher).str); @@ -59,7 +59,7 @@ int main() printf("\t[%d]: %s\n", i, format_aes_block128_fips_style(&inverted_schedule.keys[i]).str); } - decrypted = aes128cbc_decrypt(cypher, &inverted_schedule, &iv); + decrypted = aes128cbc_decrypt(cypher, &inverted_schedule, iv); printf("\n"); printf("Decrypted: %s\n", format_aes_block128(&decrypted).str); printf(" %s\n", format_aes_block128_fips_style(&decrypted).str); |