Skip to content

Unable to use 'crypto.constants.RSA_PKCS1_OAEP_PADDING' #68

@ahadtechcarrot

Description

@ahadtechcarrot

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 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?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions