react-native-quick-crypto icon indicating copy to clipboard operation
react-native-quick-crypto copied to clipboard

Are authentication tags validated?

Open nishils opened this issue 1 year ago • 2 comments

Hi there,

I can't get authentication tags to validate when using chacha20-poly1305. Decryption works just fine but when I purposefully mangle the authentication tag or the additional authenticated data (aad), it decrypts just fine.

Is there a specific order to run setAAD, update, and setAuthTag or some way to detect this failure mode?

This could be a bug or just user error. Unsure at this point!

Thanks!

nishils avatar Apr 20 '23 04:04 nishils

Did you get an answer for this?

MahmoudNafiseh avatar Apr 27 '23 16:04 MahmoudNafiseh

@MahmoudNafiseh nope. As far as I can tell, they are not validated and can't find a way to get them validated.

nishils avatar May 02 '23 20:05 nishils