Skip to content

AsyncHttpProviderUtils.getRedirectUri() throws IllegalArgumentException if "location" argument contains space characters. #268

@amakarenko

Description

@amakarenko

When I'm trying to fetch page from next URL "http://www.ebay.de/itm/FSC-Lifebook-E8310-Core2Duo-T8100-2-1GHz-4GB-DVD-RW-/150731406505?pt=DE_Technik_Computer_Peripherieger%C3%A4te_Notebooks&hash=item23184abca9#ht_1960wt_1140"

AsyncHttpClient is failing inside AsyncHttpProviderUtils.getRedirectUri() with exception:

java.lang.IllegalArgumentException: Illegal character in query at index 84: http://www.ebay.de/sch/sis.html;jsessionid=92D73F80262E3EBED7E115ED01035DDA?_nkw=FSC Lifebook E8310 Core2Duo T8100 2 1GHz 4GB DVD RW&_itemId=150731406505
at java.net.URI.create(URI.java:859) ~[na:1.7.0_09]
at java.net.URI.resolve(URI.java:1043) ~[na:1.7.0_09]
at com.ning.http.util.AsyncHttpProviderUtils.getRedirectUri(AsyncHttpProviderUtils.java:233) ~[async-http-client-1.7.12.jar:na]
at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.redirect(NettyAsyncHttpProvider.java:2063) ~[async-http-client-1.7.12.jar:na]

Seams, that AsyncHttpProviderUtils.getRedirectUri() does not pre-process "location" argument, retrieved from "Location" Http Header.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions