-
Notifications
You must be signed in to change notification settings - Fork 21
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
ErrorException thrown during decryption when IV is too short #69
Comments
Hi @phptek I also have gotten this on and off for some time:
It is very occasionally, and it's almost always when some form of search bot is browsing around, though - and never from normal users it appears. Unsure if that's simply a coincidence though. Would simply adding a base64 encode/decode to ensure that Edit: that is, to clarify - an encode/decode on the |
In some circumstances,
OpenSSLCrypto::decrypt()
will throw anErrorException
when the IV passed toopenssl_decrypt()
is of an invalid length as returned fromopenssl_cipher_iv_length()
(PHP will attempt to zero-pad it in this case).IMO the logic should probably try to pad it prior to being passed to
openssl_decrypt()
.This isn't super-critical given that PHP sends this as a
WARNING
.The text was updated successfully, but these errors were encountered: