Alan Toledo

Results 5 comments of Alan Toledo

`publicKey.encrypt("");` everytime i want decrypt, i need create any encrypt for can decrypt anything. If I remove that line, I get this error:: ``` throw Error('Error during decryption (probably incorrect...

```js const { RSA, Wallet } = require("../core"); const { publicKey, privateKey } = RSA.getKeys(); const create = () => { const wallet = Wallet.create(); const address = wallet.address; const...

Step1 ```js const NodeRSA = require("node-rsa"); const privateKey = new NodeRSA("your private key"); const publicKey = new NodeRSA("you public key"); const encrypt = ( data ) => { const encryptedData=...

Hi, I had the same error. i fixed it like this: https://github.com/rzcoder/node-rsa/issues/215#issuecomment-1100953336 ```js publicKey.encrypt(""); const decryptedData = privateKey.decrypt("your base64 encryption", "utf8"); ```