-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
encryption returning false #296
Comments
i also have the similar issue after i upgraded to latest version. now i get error message |
Most probably the public key is invalid, for some reason. Double check that. |
The way to declare your public key is : const publicKeyCasting =
"-----BEGIN PUBLIC KEY-----MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDY0xIs5oSVl8dxCW4zDTtIdtfOVMjT8bI6l6tDb3BW6HSIAXqEsp6wfeVHJ+7LHFDGSn4TrURpL6FFKHPz7EVzZrcZjNU+jn8l2W9hDXnFc/v3qR3SRXuG71ZUiCP3g8j1SdY+sB0Yn0046PdFiWrIX8qiqMpNX2fHiJH5uq71/QIDAQAB-----END PUBLIC KEY-----" |
Same problem here. Tried every variation of encoding, preceding key with the "-----BEGIN PUBLIC KEY-----" and following with "-----END PUBLIC KEY-----"... it all results in false. |
I'm trying to encrypt some text with a server public key, but it keeps returning false for whatever reason.
Example pub key from server:
Client code:
The text was updated successfully, but these errors were encountered: