Tidy & Update doc

This commit is contained in:
Christophe Maudoux 2020-08-28 23:50:57 +02:00
parent 779fd983e5
commit b4222b50f3
3 changed files with 12 additions and 7 deletions

View File

@ -21,7 +21,7 @@ backups and a rollback plan ready!
-----
- | Bad default value to display OIDC Consents tab has been fixed.
| The default value is ``$_oidcConsents``
| The default value is ``$_oidcConsents && $_oidcConsents =~ /\w+/``
- Some user log messages have been modified, check :doc:`logs documentation <logs>`
(see also `#2244 <https://gitlab.ow2.org/lemonldap-ng/lemonldap-ng/issues/2244>`__)
- SAML SOAP calls are now using ``text/xml`` instead of ``application/xml`` as the MIME Content Type, as required by `the SOAP standard <https://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383526>`__
@ -36,6 +36,8 @@ backups and a rollback plan ready!
- This release fixes several issues when using ``SameSite=None``. The new
default value of the SameSite configuration parameter will set SameSite to
``Lax`` unless you are using SAML, which requires ``None``
- Incremental lock times values can now be set by using Manager.
It must a list of comma separated values. Default values are ``5, 15, 60, 300, 600``
2.0.8
-----

View File

@ -40,7 +40,7 @@ has unrestrictedUsersRule => ( is => 'rw', default => sub { 0 } );
sub init {
my ($self) = @_;
$self->addAuthRoute( switchcontext => 'run', ['POST'] )
$self->addAuthRoute( switchcontext => 'run', ['POST'] )
->addAuthRoute( switchcontext => 'display', ['GET'] );
# Parse ContextSwitching rules
@ -193,7 +193,7 @@ sub run {
$self->userLogger->notice(
"ContextSwitching: Update \"$realId\" session with \"$spoofId\" session data"
);
$req->mustRedirect(1);
return $self->p->do( $req, [ sub { $statut } ] );
}

View File

@ -2,8 +2,11 @@ package Lemonldap::NG::Portal::Plugins::Impersonation;
use strict;
use Mouse;
use Lemonldap::NG::Portal::Main::Constants
qw( PE_OK PE_BADCREDENTIALS PE_IMPERSONATION_SERVICE_NOT_ALLOWED PE_MALFORMEDUSER );
use Lemonldap::NG::Portal::Main::Constants qw(
PE_OK PE_BADCREDENTIALS
PE_IMPERSONATION_SERVICE_NOT_ALLOWED
PE_MALFORMEDUSER
);
our $VERSION = '2.0.9';
@ -77,7 +80,7 @@ sub run {
return $req->authResult
if $req->authResult >
PE_OK; # Skip Impersonation if error during Auth process
PE_OK; # Skip Impersonation if an error occurs during Auth process
my $statut = PE_OK;
my $unUser = 0;
@ -86,7 +89,7 @@ sub run {
$req->{user} ||= $req->{sessionInfo}->{_impUser}; # If 2FA is enabled
my $spoofId = $req->param('spoofId') # Impersonation required
|| $req->{sessionInfo}->{_impSpoofId} # If 2FA is enabled
|| $req->{user}; # NO Impersonation required
|| $req->{user}; # Impersonation not required
$self->logger->debug("No impersonation required")
if ( $spoofId eq $req->{user} );