aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/examples/aes128cbc.c
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2015-06-04 17:05:24 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2015-06-04 17:05:24 +0300
commita497b83f80508747151dacf660f7d5de48d0464f (patch)
treeb2ded10280830aa31b3be10e2b81fc1a42df65e0 /examples/aes128cbc.c
parentrefactoring (diff)
downloadaes-tools-a497b83f80508747151dacf660f7d5de48d0464f.tar.gz
aes-tools-a497b83f80508747151dacf660f7d5de48d0464f.zip
explicitly separate BE vs. LE block I/O functions
Diffstat (limited to 'examples/aes128cbc.c')
-rw-r--r--examples/aes128cbc.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/examples/aes128cbc.c b/examples/aes128cbc.c
index ab12df8..05b91b0 100644
--- a/examples/aes128cbc.c
+++ b/examples/aes128cbc.c
@@ -20,15 +20,15 @@ int main()
iv = make_aes_block128(0xfedcba98, 0x76543210, 0xfedcba98, 0x76543210);
printf("Plain: %s\n", format_aes_block128(&plain).str);
- print_aes_block128_fips_matrix_style(&plain);
+ print_aes_block128_as_matrix(&plain);
printf("\n");
printf("Key: %s\n", format_aes_block128(&key).str);
- print_aes_block128_fips_matrix_style(&key);
+ print_aes_block128_as_matrix(&key);
printf("\n");
printf("Initialization vector: %s\n", format_aes_block128(&iv).str);
- print_aes_block128_fips_matrix_style(&iv);
+ print_aes_block128_as_matrix(&iv);
aes128_expand_key_schedule(key, &key_schedule);
@@ -40,11 +40,11 @@ int main()
cipher = aes128cbc_encrypt(plain, &key_schedule, iv, &next_iv);
printf("\n");
printf("Cipher: %s\n", format_aes_block128(&cipher).str);
- print_aes_block128_fips_matrix_style(&cipher);
+ print_aes_block128_as_matrix(&cipher);
printf("\n");
printf("Next initialization vector: %s\n", format_aes_block128(&next_iv).str);
- print_aes_block128_fips_matrix_style(&next_iv);
+ print_aes_block128_as_matrix(&next_iv);
aes128_invert_key_schedule(&key_schedule, &inverted_schedule);
@@ -56,11 +56,11 @@ int main()
decrypted = aes128cbc_decrypt(cipher, &inverted_schedule, iv, &next_iv);
printf("\n");
printf("Decrypted: %s\n", format_aes_block128(&decrypted).str);
- print_aes_block128_fips_matrix_style(&decrypted);
+ print_aes_block128_as_matrix(&decrypted);
printf("\n");
printf("Next initialization vector: %s\n", format_aes_block128(&next_iv).str);
- print_aes_block128_fips_matrix_style(&next_iv);
+ print_aes_block128_as_matrix(&next_iv);
return 0;
}