You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to access the RabbitMO management API, I figured out, that it is impossible to send a request to an URL containing an escaped slash '/', i.e. '/api/exchanges/%2f/amq.direct'
That's mainly because the java URI(scheme,...,...) constructor would do a toString() first qouting/escaping all parameters and than parse the resulting string; during the toString() however the path is quoted/encoded, so a a string like '%2f' is written out as '%252f'.
And specifying the path as '/api///whatever' is not a solution either, as the '/' is valid path character, and does not get escaped.
One might surely argue, that this is Java URI problem, however it prevents unirest-java to be used with URIs containing an escaped '/'.
Inside com.mashape.unirest.http.HttpClientHelper method prepareRequest, the URL is split up into an URI where the path is url-decoded. This url-decoding seems not correct.
For me it creates http://host/v1/guid//test/tree
from http://host/v1/guid/%2Ftest/tree
which then leads to a 404 on the server.
The text was updated successfully, but these errors were encountered:
From #160
Trying to access the RabbitMO management API, I figured out, that it is impossible to send a request to an URL containing an escaped slash '/', i.e. '/api/exchanges/%2f/amq.direct'
That's mainly because the java URI(scheme,...,...) constructor would do a toString() first qouting/escaping all parameters and than parse the resulting string; during the toString() however the path is quoted/encoded, so a a string like '%2f' is written out as '%252f'.
And specifying the path as '/api///whatever' is not a solution either, as the '/' is valid path character, and does not get escaped.
One might surely argue, that this is Java URI problem, however it prevents unirest-java to be used with URIs containing an escaped '/'.
Inside com.mashape.unirest.http.HttpClientHelper method prepareRequest, the URL is split up into an URI where the path is url-decoded. This url-decoding seems not correct.
For me it creates
http://host/v1/guid//test/tree
from
http://host/v1/guid/%2Ftest/tree
which then leads to a 404 on the server.
The text was updated successfully, but these errors were encountered: