Closed CHUN-WEI-HSU closed 5 years ago
@gesrt We will check and let you know.
Could you please send us the AES256 plugin and Xcode version details.
Thank you for your assistance. Xcode Version 10.0 (10A255) Plugin Version 1.1.0
sorry for my bad english.
In my case it also works fine on Android but on iOS the decryption always returns NULL. Could this be related?
Hi @flowli ,
We will look on to this issue. If possible could you please provide us the some additional info,
Have you used the "generateSecureKey" function for creating the secure key?
If you have used own SecureKey then the length should be 32 and for the secure IV length should be 16
I generate the params with this:
import rand from 'csprng';
let params = {
key: await this.aes.generateSecureKey(rand(256, 16).toString()),
iv: await this.aes.generateSecureIV(rand(128, 16).toString()),
};
This gets stored securely and is later fed to the encrypt/decrypt methods.
Thanks @flowli , Could you please send us the generated sample key and iv, AES256 plugin and Xcode version details.
After generating a new key (didn't save the old one) it appears to work. Will let you know when the problem re-appears. Thanks a lot so far!
I have the same issue as gesrt:
Error: Plugin Optional("AES256") does not respond to method call generateSecureKey:.
Ensure plugin method exists and uses @objc in its declaration
Xcode Version 10.1 (10B61) Plugin Version 1.1.0
installed with capacitor: npm install cordova-plugin-nativestorage
I got an error messages in xCode. it works find in Android