diff options
| author | Kévin Le Gouguec <kevin.legouguec@airbus.com> | 2019-03-22 15:15:10 +0100 |
|---|---|---|
| committer | Kévin Le Gouguec <kevin.legouguec@airbus.com> | 2019-03-22 15:15:10 +0100 |
| commit | a8701ca89867b85b10ee932d68c0188633485437 (patch) | |
| tree | 2e361765c88e6232fcfaacb3874f0f99150cb4ff /test/i-192/traces-ae.c | |
| parent | 66287d37ee996d7ee8e067ff649720cbbab9bae2 (diff) | |
| download | lilliput-ae-implem-a8701ca89867b85b10ee932d68c0188633485437.tar.xz | |
Ajout de traces pour le déchiffrement AE
Pour aider l'implémentation matérielle.
Diffstat (limited to 'test/i-192/traces-ae.c')
| -rw-r--r-- | test/i-192/traces-ae.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/i-192/traces-ae.c b/test/i-192/traces-ae.c index c5d4820..6448928 100644 --- a/test/i-192/traces-ae.c +++ b/test/i-192/traces-ae.c @@ -128,6 +128,19 @@ int main(int argc, char **argv) debug_dump_buffer("ciphertext", v->message_len, ciphertext, 0); debug_dump_buffer("tag", TAG_BYTES, tag, 0); + fprintf(DUMP, "DECRYPTING\n"); + + uint8_t cleartext[v->message_len]; + lilliput_ae_decrypt( + sizeof(ciphertext), ciphertext, + v->auth_len, v->auth, + v->key, v->nonce, + tag, + cleartext + ); + + debug_dump_buffer("cleartext", sizeof(cleartext), cleartext, 0); + fclose(DUMP); } } |
