Skip to content

Commit ce3b7bb

Browse files
authored
Merge pull request #473 from nasa/401-create-tc_process-ut-to-exercise-iv-and-arsn-counters
[#401] Readded UT and MAC debug comments
2 parents 552a20f + 8d069b9 commit ce3b7bb

File tree

2 files changed

+246
-228
lines changed

2 files changed

+246
-228
lines changed

src/crypto/libgcrypt/cryptography_interface_libgcrypt.template.c

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -901,6 +901,27 @@ static int32_t cryptography_aead_decrypt(uint8_t *data_out, size_t len_data_out,
901901

902902
if (authenticate_bool == CRYPTO_TRUE)
903903
{
904+
// ********** USED FOR TAG DEBUGGING ***********
905+
// ********* DO NOT USE IN PRODUCTION **********
906+
907+
// printf("Received MAC is: \n\t0x");
908+
// for (uint32_t i = 0; i < mac_size; i++)
909+
// {
910+
// printf("%02X", mac[i]);
911+
// }
912+
// printf("\n");
913+
914+
// gcry_error = gcry_cipher_gettag(tmp_hd,
915+
// mac,
916+
// mac_size);
917+
918+
// printf("Calculated MAC is: \n\t0x");
919+
// for (uint32_t i = 0; i < mac_size; i++)
920+
// {
921+
// printf("%02X", mac[i]);
922+
// }
923+
// printf("\n");
924+
904925
gcry_error = gcry_cipher_checktag(tmp_hd,
905926
mac, // tag input
906927
mac_size // tag size

0 commit comments

Comments
 (0)