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

bug: setAuthTag fails with invalid authentication tag length

Open samuelscheit opened this issue 2 years ago • 0 comments

I have set up the example application and ran the createCipher/createDecipher unit test. All tests pass except the last one which returns the following error for the test setAutoPadding/setAuthTag/setAAD:

Invalid authentication tag length
image

I've debugged the problem and it does not matter if you use Buffer.from("auth_tag") (just like the unit test) or Uint8Array or ArrayBuffer as tag input, the auth_tag_len_ variable (in MGLCipherHostObject.cpp) is always 0.

samuelscheit avatar May 07 '23 00:05 samuelscheit