From: Moritz Bunkus Date: Sat, 9 Jan 2010 10:49:13 +0000 (+0100) Subject: Cookie-Base-Path richtig berechnen. X-Git-Tag: release-2.6.2beta1~331^2~20 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=07036bf10657855cc7b59f7c978bb6ab0d2d065a;p=kivitendo-erp.git Cookie-Base-Path richtig berechnen. Commit 0c50616fb43bcf934101fadd488278c40317b586 hat den Cookie-Gültigkeits-Pfad leider inklusive des Scriptnamens gesetzt, wodurch nur noch Zugriff auf login.pl möglich war. --- diff --git a/SL/Form.pm b/SL/Form.pm index 5f0fcd756..d85fe54da 100644 --- a/SL/Form.pm +++ b/SL/Form.pm @@ -566,12 +566,17 @@ sub create_http_response { my $session_cookie; if (defined $main::auth) { + my $uri = $self->_get_request_uri; + my @segments = $uri->path_segments; + pop @segments; + $uri->path_segments(@segments); + my $session_cookie_value = $main::auth->get_session_id(); $session_cookie_value ||= 'NO_SESSION'; $session_cookie = $cgi->cookie('-name' => $main::auth->get_session_cookie_name(), '-value' => $session_cookie_value, - '-path' => $self->_get_request_uri->path, + '-path' => $uri->path, '-secure' => $ENV{HTTPS}); }