-
Notifications
You must be signed in to change notification settings - Fork 134
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
Index out of range: index should be less than 36: 36 #53
Comments
When not padded, inputs should be multiples of the block size. Can you share your input or an input that reproduces the error? |
Hi @leocavalcante 👋 Sure thing. I'm trying to encrypt a String of
I get this error: On a higher level, what I'm trying to do is be able to encrypt/decrypt in my Flutter app (using
If I encrypt the string
If I encrypt the string
But if I set Would you mind elaborating on your point, with respect to what I'm trying to do as per above? I'm quite new to encryption. Thanks for your time. |
I managed to figure this out. Ended up using CBC instead of CTR, with padding. Closing this issue. |
Hi there!
I'm having an issue when I try to pass
padding: null
to the AES encrypter. I'm getting exception:flutter: Another exception was thrown: RangeError (index): Index out of range: index should be less than 36: 36
All I'm doing (so far) is instantiating a Crypto object and calling
encrypt
on a string. Here's my Crypto class:And here's the full debug console:
I don't get this error when I remove
padding: null
from the Encrypter. But, I'm already encrypting using AES.ctr in my web app (using the aesjs library), which doesn't add padding.Can you point me in the right direction?
Thanks for your help!
The text was updated successfully, but these errors were encountered: