I have setup the react-native-crypto library and everything is working fine, but I wanted to use crypto.constants.RSA_PKCS1_OAEP_PADDING in
const encryptedData = crypto.publicEncrypt( { key: publicKey, padding: crypto.constants.RSA_PKCS1_OAEP_PADDING, oaepHash: "sha256", }, Buffer.from(textData) );
which is not working and throwing exception and if I comment it out then it will generate a new encrypted value on every call. Can someone help me regarding this issue?
Hi,
I have setup the react-native-crypto library and everything is working fine, but I wanted to use
crypto.constants.RSA_PKCS1_OAEP_PADDING
inconst encryptedData = crypto.publicEncrypt( { key: publicKey, padding: crypto.constants.RSA_PKCS1_OAEP_PADDING, oaepHash: "sha256", }, Buffer.from(textData) );
which is not working and throwing exception and if I comment it out then it will generate a new encrypted value on every call. Can someone help me regarding this issue?