Skip to content

NettyAsyncHttpProvider not following redirect to lower-cased path #127

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

Closed
kamatsuoka opened this issue Jul 7, 2012 · 1 comment
Closed
Milestone

Comments

@kamatsuoka
Copy link

In NettyAsyncHttpProvider.java, when handling an HTTP redirect, it checks whether the new url is the same as the old url, ignoring case.

It turns out that there are some web servers out there that redirect any mixed-case filenames to the lowercased equivalent.

curl -v http://www.pix-art.de/sykhjN6md5ysGCqDIbm6lt35suI.html
> GET /sykhjN6md5ysGCqDIbm6lt35suI.html HTTP/1.1
> Host: www.pix-art.de
>
< HTTP/1.1 301 Moved Permanently
< Location: http://www.pix-art.de/sykhjn6md5ysgcqdibm6lt35sui.html
< Server: Microsoft-IIS/7.5
< X-Powered-By: ASP.NET

So if you try to get the mixed-case filename, NettyAsyncHttpProvider won't follow the redirect.

jfarcand pushed a commit that referenced this issue Sep 6, 2012
Issue #127 mentions that the NettyHttpProvider ignores case when checking for equality between the redirect Uri and the Future's Uri. This commit simply changes the equalsIgnoreCase to equals.
jfarcand added a commit that referenced this issue Sep 6, 2012
FIX ISSUE #127 NettyAsyncHttpProdiver redirects ignoring case
@slandelle
Copy link
Contributor

Needs to be backported on 1.7.x

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

2 participants