Skip to content
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

thumbor:WARNING Malformed URL #20

Open
everlastin opened this issue Jul 2, 2015 · 13 comments
Open

thumbor:WARNING Malformed URL #20

everlastin opened this issue Jul 2, 2015 · 13 comments

Comments

@harto
Copy link
Contributor

harto commented Jul 2, 2015

What version of Thumbor are you using? Which of the URLs causes the error?

@everlastin
Copy link
Author

We are using version 4.12.2 and both URLs are failing. Unsafe URLs work without any issues which is good for development, but we want to make use of the secure URLs when we go live. Any thoughts?

@harto
Copy link
Contributor

harto commented Jul 2, 2015

I'm not quite sure. Can you confirm that you get a different URL when you use thumbor-url to generate the URL? E.g.:

thumbor-url --key="<key>" --width=252 --height=198 https://s3.amazonaws.com/bucket-name/rP1ysDPH_Photo_Apr_18_8_46_13_PM.jpg

@everlastin
Copy link
Author

Same result as the first URL above:
/5DlvHS38TZ3OTS2t7qKdKzN6lU4=/252x198/https://s3.amazonaws.com/bucket-name/rP1ysDPH_Photo_Apr_18_8_46_13_PM.jpg

Could it be the version of Thumbor we are using?

@harto
Copy link
Contributor

harto commented Jul 6, 2015

Perhaps your production Thumbor server is misconfigured. Is it definitely using the same key you're using to generate these URLs?

@jbouzekri
Copy link
Contributor

Could it be because the last part of your url is not urlencoded ?

@matthlavacka
Copy link

How did you guys solve this? Having the same issue right now

@matthlavacka
Copy link

@harto That was our case. Probably might be worth mentioning it better in docs

@roelvanduijnhoven
Copy link

Mm. So we should manually encode the URLs we send to thes library?

If so: why is this not handled by the library? Looks like a bug to me!

@mpdude
Copy link

mpdude commented Dec 3, 2018

At least in newer Thumbor versions, the entire image URL should be urlencoded, since it is used as an URL part itself. This library should handle that.

@mpdude
Copy link

mpdude commented Dec 5, 2018

I think I've fixed this in webfactory#1, you could try webfactory/phumbor: ^1.2.3 on Composer.

@bkonetzny
Copy link

I can confirm that the fix in webfactory/phumbor: ^1.2.3 solves the issue. @mpdude Can you create a PR for this?

@mpdude
Copy link

mpdude commented Jan 30, 2019

Since this issue here is three years old and as #21 also tries to fix it (in a slightly different way), my assumption was that this project here has been abandoned.

That’s why I forked it (with a heavy heart) and re-published it as webfactory/phumbor.

mpdude added a commit to mpdude/PhumborBundle that referenced this issue Oct 31, 2019
The `99designs/phumbor` library has been unmaintained for a long time. In particular, there is a long-standing issue regarding application of `rawurlencode()` to image URLs (99designs/phumbor#20) which has not been addressed. Also the (direct question whether the code is still maintained or not)[99designs/phumbor#30] has not been answered for almost a year.

In order to address the URL encoding issue, I forked the original repo:

* https://github.com/webfactory/phumbor/
* https://packagist.org/packages/webfactory/phumbor

With this change I would like to suggest switching this bundle over to the forked library.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants