Item14396: Redirect issue after login on Lighttpd
Priority: Normal
Current State: Closed
Released In: 2.1.4
Target Release: patch
A login issue was reported on
Support.Question1873. The questioner eventually isolated the issue to a problem in the redirect after login.
Found it! See https://tools.ietf.org/html/rfc3875#section-6.2.2
The TemplateLogin->login
method redirects to what by CGI specs is called local-Location. According to RFC 3875
, in this case The script MUST NOT return any other header fields or a message-body, and the server MUST generate the response that it would have produced in response to a request containing the URL
scheme "://" server-name ":" server-port local-pathquery
In other words, setting a cookie without giving full redirect URL is violation of CGI protocol. If I add $query->url(base => 1, full => 1)
to $origurl
in the TemplateLogin->login
, everything works as expected.
-- AlexanderSmishlajev - 09 May 2017
I'm not sure how to apply the suggested change to Foswiki::LoginManager::TemplateLogin. I've been unable to recreate the issue.
--
GeorgeClark - 09 May 2017