Revision 6c21fd13
Von Moritz Bunkus vor mehr als 12 Jahren hinzugefügt
SL/Dispatcher/AuthHandler/User.pm | ||
---|---|---|
$::locale = Locale->new($::myconfig{countrycode});
|
||
$::request->{layout} = SL::Layout::Dispatcher->new(style => $::myconfig{menustyle});
|
||
|
||
my $ok = $::form->{'{AUTH}login'} && (SL::Auth::OK() == $::auth->authenticate($::myconfig{login}, $::form->{'{AUTH}password'}));
|
||
my $ok = $::auth->get_api_token_cookie ? 1 : 0;
|
||
$ok ||= $::form->{'{AUTH}login'} && (SL::Auth::OK() == $::auth->authenticate($::myconfig{login}, $::form->{'{AUTH}password'}));
|
||
$ok ||= !$::form->{'{AUTH}login'} && (SL::Auth::OK() == $::auth->authenticate($::myconfig{login}, undef));
|
||
|
||
return $self->_error(%param) if !$ok;
|
Auch abrufbar als: Unified diff
Automatische Authentifizierung bestehender Sessions über Session-ID + API-Token
Wird für CRM-Menü benötigt.