- correcting old style specific handlers (reinjecting modification from
SpecificHandlers/*.pm) - adding a comment line to indicate which style is the current specific handler and how it is supposed to be launched - adapting DefaultHandler.pm to permit tests passing configuration file parameter (references #630)
This commit is contained in:
parent
2408e9e4af
commit
1c5d4d8c32
|
@ -3,6 +3,10 @@
|
||||||
|
|
||||||
##@class
|
##@class
|
||||||
# Auth-basic authentication with Lemonldap::NG rights management
|
# Auth-basic authentication with Lemonldap::NG rights management
|
||||||
|
|
||||||
|
# This specific handler is intended to be called by a handler caller
|
||||||
|
# old working, kept for compatibility with previous 1.4.0 versions
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::AuthBasic;
|
package Lemonldap::NG::Handler::AuthBasic;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
|
|
@ -41,6 +41,10 @@ our $reloadTime;
|
||||||
our $lmConf;
|
our $lmConf;
|
||||||
our $localConfig;
|
our $localConfig;
|
||||||
|
|
||||||
|
my $conf = defined($GLOBAL::testInput)
|
||||||
|
? $GLOBAL::testInput
|
||||||
|
: {};
|
||||||
|
|
||||||
BEGIN {
|
BEGIN {
|
||||||
if ( MP() == 2 ) {
|
if ( MP() == 2 ) {
|
||||||
eval {
|
eval {
|
||||||
|
@ -258,7 +262,7 @@ sub refresh($$) {
|
||||||
return OK;
|
return OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
__PACKAGE__->init( {} );
|
__PACKAGE__->init( $conf );
|
||||||
|
|
||||||
1;
|
1;
|
||||||
__END__
|
__END__
|
||||||
|
|
|
@ -5,6 +5,10 @@
|
||||||
# Secure Token
|
# Secure Token
|
||||||
#
|
#
|
||||||
# Create a secure token used to resolve user identity by a protected application
|
# Create a secure token used to resolve user identity by a protected application
|
||||||
|
|
||||||
|
# This specific handler is intended to be called by a handler caller
|
||||||
|
# old working, kept for compatibility with previous 1.4.0 versions
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::SecureToken;
|
package Lemonldap::NG::Handler::SecureToken;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
@ -32,6 +36,15 @@ BEGIN {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
## @imethod protected void globalInit(hashRef args)
|
||||||
|
# Overload globalInit to launch this class defaultValuesInit
|
||||||
|
# @param $args reference to the configuration hash
|
||||||
|
sub globalInit {
|
||||||
|
my $class = shift;
|
||||||
|
__PACKAGE__->defaultValuesInit(@_);
|
||||||
|
$class->SUPER::globalInit(@_);
|
||||||
|
}
|
||||||
|
|
||||||
## @imethod protected void defaultValuesInit(hashRef args)
|
## @imethod protected void defaultValuesInit(hashRef args)
|
||||||
# Overload defaultValuesInit
|
# Overload defaultValuesInit
|
||||||
# @param $args reference to the configuration hash
|
# @param $args reference to the configuration hash
|
||||||
|
|
|
@ -3,6 +3,9 @@
|
||||||
|
|
||||||
##@class
|
##@class
|
||||||
# Auth-basic authentication with Lemonldap::NG rights management
|
# Auth-basic authentication with Lemonldap::NG rights management
|
||||||
|
|
||||||
|
# This specific handler is intended to be called directly by Apache
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::SpecificHandlers::AuthBasic;
|
package Lemonldap::NG::Handler::SpecificHandlers::AuthBasic;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
# Secure Token
|
# Secure Token
|
||||||
#
|
#
|
||||||
# Create a secure token used to resolve user identity by a protected application
|
# Create a secure token used to resolve user identity by a protected application
|
||||||
|
|
||||||
|
# This specific handler is intended to be called directly by Apache
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::SpecificHandlers::SecureToken;
|
package Lemonldap::NG::Handler::SpecificHandlers::SecureToken;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
# Sympa autologin
|
# Sympa autologin
|
||||||
#
|
#
|
||||||
# Build Sympa cookie and send it to Sympa
|
# Build Sympa cookie and send it to Sympa
|
||||||
|
|
||||||
|
# This specific handler is intended to be called directly by Apache
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::SpecificHandlers::SympaAutoLogin;
|
package Lemonldap::NG::Handler::SpecificHandlers::SympaAutoLogin;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
|
|
@ -3,6 +3,9 @@
|
||||||
|
|
||||||
## @class
|
## @class
|
||||||
# Lemonldap::NG special handler
|
# Lemonldap::NG special handler
|
||||||
|
|
||||||
|
# This specific handler is intended to be called directly by Apache
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::SpecificHandlers::UpdateCookie;
|
package Lemonldap::NG::Handler::SpecificHandlers::UpdateCookie;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
# Zimbra preauthentication
|
# Zimbra preauthentication
|
||||||
#
|
#
|
||||||
# It will build Zimbra preauth URL
|
# It will build Zimbra preauth URL
|
||||||
|
|
||||||
|
# This specific handler is intended to be called directly by Apache
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::SpecificHandlers::ZimbraPreAuth;
|
package Lemonldap::NG::Handler::SpecificHandlers::ZimbraPreAuth;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
|
|
@ -5,6 +5,10 @@
|
||||||
# Sympa autologin
|
# Sympa autologin
|
||||||
#
|
#
|
||||||
# Build Sympa cookie and send it to Sympa
|
# Build Sympa cookie and send it to Sympa
|
||||||
|
|
||||||
|
# This specific handler is intended to be called by a handler caller
|
||||||
|
# old working, kept for compatibility with previous 1.4.0 versions
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::SympaAutoLogin;
|
package Lemonldap::NG::Handler::SympaAutoLogin;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
@ -19,6 +23,15 @@ our $VERSION = '1.1.2';
|
||||||
# Shared variables
|
# Shared variables
|
||||||
our ( $sympaSecret, $sympaMailKey );
|
our ( $sympaSecret, $sympaMailKey );
|
||||||
|
|
||||||
|
## @imethod protected void globalInit(hashRef args)
|
||||||
|
# Overload globalInit to launch this class defaultValuesInit
|
||||||
|
# @param $args reference to the configuration hash
|
||||||
|
sub globalInit {
|
||||||
|
my $class = shift;
|
||||||
|
__PACKAGE__->defaultValuesInit(@_);
|
||||||
|
$class->SUPER::globalInit(@_);
|
||||||
|
}
|
||||||
|
|
||||||
## @imethod protected void defaultValuesInit(hashRef args)
|
## @imethod protected void defaultValuesInit(hashRef args)
|
||||||
# Overload defaultValuesInit
|
# Overload defaultValuesInit
|
||||||
# @param $args reference to the configuration hash
|
# @param $args reference to the configuration hash
|
||||||
|
|
|
@ -3,6 +3,10 @@
|
||||||
|
|
||||||
## @class
|
## @class
|
||||||
# Lemonldap::NG special handler
|
# Lemonldap::NG special handler
|
||||||
|
|
||||||
|
# This specific handler is intended to be called by a handler caller
|
||||||
|
# old working, kept for compatibility with previous 1.4.0 versions
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::UpdateCookie;
|
package Lemonldap::NG::Handler::UpdateCookie;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
|
|
@ -5,6 +5,10 @@
|
||||||
# Zimbra preauthentication
|
# Zimbra preauthentication
|
||||||
#
|
#
|
||||||
# It will build Zimbra preauth URL
|
# It will build Zimbra preauth URL
|
||||||
|
|
||||||
|
# This specific handler is intended to be called by a handler caller
|
||||||
|
# old working, kept for compatibility with previous 1.4.0 versions
|
||||||
|
|
||||||
package Lemonldap::NG::Handler::ZimbraPreAuth;
|
package Lemonldap::NG::Handler::ZimbraPreAuth;
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
|
@ -20,6 +24,15 @@ our $VERSION = '1.0.0';
|
||||||
our ( $zimbraPreAuthKey, $zimbraAccountKey, $zimbraBy, $zimbraUrl,
|
our ( $zimbraPreAuthKey, $zimbraAccountKey, $zimbraBy, $zimbraUrl,
|
||||||
$zimbraSsoUrl, $timeout );
|
$zimbraSsoUrl, $timeout );
|
||||||
|
|
||||||
|
## @imethod protected void globalInit(hashRef args)
|
||||||
|
# Overload globalInit to launch this class defaultValuesInit
|
||||||
|
# @param $args reference to the configuration hash
|
||||||
|
sub globalInit {
|
||||||
|
my $class = shift;
|
||||||
|
__PACKAGE__->defaultValuesInit(@_);
|
||||||
|
$class->SUPER::globalInit(@_);
|
||||||
|
}
|
||||||
|
|
||||||
## @imethod protected void defaultValuesInit(hashRef args)
|
## @imethod protected void defaultValuesInit(hashRef args)
|
||||||
# Overload defaultValuesInit
|
# Overload defaultValuesInit
|
||||||
# @param $args reference to the configuration hash
|
# @param $args reference to the configuration hash
|
||||||
|
|
Loading…
Reference in New Issue
Block a user