Bug #14009
openHttp::Client not handling redirect (302) on ssl stream truncated error
0%
Description
Hello,
I have setup a Wt::Http::Client using setFollowRedirect(true).
However, the done callback is called without following the redirection:
MyCallbackClientDone(Wt::AsioWrapper::error_code ec, const Wt::Http::Message& msg)
{
std::cout << "Client done. ec = " << ec.category().name() << " - " << ec.message() << " (" << ec.value() << "), status = " << msg.status();
}
=>
According to Wt's Client::handleRedirect, it is likely we don't enter the if because of !err
if (!err && (((status == STATUS_MOVED_PERMANENTLY ||
status == STATUS_FOUND ||
status == STATUS_TEMPORARY_REDIRECT) && method == Http::Method::Get) ||
What do you think? Is there any workaround?
EP Updated by Emeric Poupon 19 days ago
Hello!
Do you have some news about this issue? Some of my users keep reporting it to me...
RM Updated by Romain Mardulyn 13 days ago
- Status changed from New to InProgress
- Assignee set to Romain Mardulyn
- Target version set to 4.15.0
RM Updated by Romain Mardulyn 13 days ago ยท Edited
Hi Emeric,
I do indeed see no reason to stop the redirection due to a stream_truncated error here. There is no reason to care about the body of the request, and if the response was truncated before the end of the headers, the headers would not be parsed, so the redirecting is already prevented in that case anyway.
As for any workaround, I do not see any. The change needs to happen in Wt.
RM Updated by Romain Mardulyn 13 days ago
- Status changed from InProgress to Review
- Assignee deleted (
Romain Mardulyn)
RM Updated by Romain Mardulyn about 16 hours ago
- Target version changed from 4.15.0 to 4.16.0
RM Updated by Romain Mardulyn about 16 hours ago
- Target version changed from 4.16.0 to 4.15.0
ED Updated by emil de keyser about 13 hours ago
- Assignee set to emil de keyser