Create stop method for AD backend (#914)

environments/ppa-mbqj77/deployments/1
Clément Oudot 9 years ago
parent 156e8be787
commit 1843fe7434
  1. 15
      lemonldap-ng-portal/lib/Lemonldap/NG/Portal/AuthAD.pm
  2. 2
      lemonldap-ng-portal/lib/Lemonldap/NG/Portal/AuthLDAP.pm

@ -7,7 +7,7 @@ package Lemonldap::NG::Portal::AuthAD;
use strict;
our $VERSION = '1.4.6';
our $VERSION = '1.9.0';
use Lemonldap::NG::Portal::Simple;
use base qw(Lemonldap::NG::Portal::AuthLDAP);
@ -124,4 +124,17 @@ sub authenticate {
return $res;
}
## @method boolean stop
# Define which error codes will stop Multi process
# @param res error code
# @return result 1 if stop is needed
sub stop {
my ( $self, $res ) = @_;
return 1
if ( $res == PE_PP_PASSWORD_EXPIRED
or $res == PE_PP_CHANGE_AFTER_RESET );
return 0;
}
1;

@ -10,7 +10,7 @@ use Lemonldap::NG::Portal::_LDAP 'ldap'; #link protected ldap
use Lemonldap::NG::Portal::_WebForm;
use Lemonldap::NG::Portal::UserDBLDAP; #inherits
our $VERSION = '1.4.0';
our $VERSION = '1.9.0';
use base qw(Lemonldap::NG::Portal::_WebForm);
*_formateFilter = *Lemonldap::NG::Portal::UserDBLDAP::formateFilter;

Loading…
Cancel
Save