Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Presenting problems to Encrypt data with the README demo #80

Open
gasparnd opened this issue Oct 11, 2023 · 1 comment
Open

Presenting problems to Encrypt data with the README demo #80

gasparnd opened this issue Oct 11, 2023 · 1 comment

Comments

@gasparnd
Copy link

I have an app with React Native v0.71.8 and "react-native-aes-crypto": "^3.0.1"

I cannot Encrypt data with the demo code in the Readme:

const encryptData = (text, key) => {
  return Aes.randomKey(16).then((iv) => {
    return Aes.encrypt(text, key, iv, "aes-256-cbc").then((cipher) => ({
      cipher,
      iv,
    }));
  });
};

export const decryptData = async () => {
 
  const res = encryptData("Flexit", "test34");

  return res;
};
@lefrankleal
Copy link

have you found solution to this? maybe error message would give us idea of what is going on with your code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants