.. | ||
py | ||
.gitignore | ||
attack_fail.png | ||
compile_commands.json | ||
pbenc_aes_ctr_hmac | ||
pbenc_aes_ctr_hmac.c | ||
plaintext | ||
Readme.md | ||
tokefile.toml |
Questao 1
Ao utilizar o programa 'chacha20_int_attck.py' sobre um criptograma produzido por 'pbenc_chacha20_poly1305', the decrpyt function will raise the execption :
- 'cryptography.exceptions.InvalidTag' – If the authentication tag doesn’t validate this exception will be raised. This will occur when the ciphertext has been changed, but will also occur when the key, nonce, or associated data are wrong.
We can try this by encrypting a message and then changing the ciphertext with the attack program: