-
Notifications
You must be signed in to change notification settings - Fork 143
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
[v5.0.3][Web] decrypt incorrect #334
Comments
Facing same issue on web. I'm using final _encrypter = Encrypter(
AES(Key.fromUtf8('key')),
);
static final _iv = IV.fromLength(16);
String encrypt(String value) {
final encrypted = _encrypter.encrypt(value, iv: _iv);
return encrypted.base64;
}
String decrypt(String value) {
var decrypt = _encrypter.decrypt64(value, iv: _iv);
return decrypt;
} |
Same issue encryption is also wrong as when going to decrypt it its give symbols in return |
THIS ID DECRYPTED Value. This is printing console as it was working fine earlier �����Pl��fY�#��~675 |
It is encryption seems okay but its also wrong because when try to decrypt it on server side it gives the same decrypt show above "x1kNa/Tk0yH13GhvwmfRGirqGqBFxOt03zqWOf5A6WQ=" |
I encountered this issue today, and after reverting to version 5.0.0, it no longer appeared. I hope the author can address this issue for versions post 5.0.0. |
the old version was not longer available I sort this issue like below get version 5.0.1 directory from my pub cached. |
I think I misunderstood the documentation.Finally, I solved it with the help of ChatGPT! After using this library since 2022, the same problem resurfaced in 2024. Now it's resolved. I’m using it on my mobile (Android), and I believe it will work on other specific devices as well. I used My issue(story) is that when the decryption has different lengths, it produces different ASCII symbols. 😅 Two years ago, I solved it by simply replacing everything ascii thats already known by debugging.
That means my system has encrypted/decrypted more than Here’s an example for decryption my code :
|
decrypt incorrect in case of Web release.
the same code decrypt correctly in the debug or encrypt v5.0.1
Flutter 3.16.4
encrypt v5.0.3
The text was updated successfully, but these errors were encountered: