* Add customFunctions and port in Manager
* Correct a bug in Handler for default values
This commit is contained in:
parent
207116b21e
commit
8538f65d04
|
@ -348,7 +348,10 @@ install_portal_site: install_conf_dir
|
|||
fi
|
||||
@$(PERL) -i -pe 's#__BINDIR__#$(BINDIR)#g;' $(RCRONDIR)/lemonldap-ng
|
||||
# Clean SVN files
|
||||
@rm -rf $$(find ${RPORTALDIR} $(RPORTALSKINSDIR) $(RLASPPORTALDIR) $(RCRONDIR) $(RCONFDIR) -type d -name .svn)
|
||||
@rm -rf $$(find ${RPORTALDIR} $(RPORTALSKINSDIR) $(RCRONDIR) $(RCONFDIR) -type d -name .svn)
|
||||
@if [ "$(WITHLA)" -eq "1" ]; then \
|
||||
rm -rf $$(find $(RLASPPORTALDIR) -type d -name .svn); \
|
||||
fi
|
||||
|
||||
install_handler_site: install_conf_dir
|
||||
# Handler install
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
# If you want to create customFunctions in rules, declare them here:
|
||||
;customFunctions => 'function1 function2',
|
||||
;customFunctions => 'Package::func1 Package::func2',
|
||||
|
||||
# CROSS-DOMAIN
|
||||
# If you have some handlers that are not registered on the main domain,
|
||||
# uncomment this
|
||||
|
@ -68,6 +69,7 @@
|
|||
# ldapBindPassword = secret
|
||||
type=File
|
||||
dirName=/var/lib/lemonldap-ng/conf
|
||||
|
||||
# LOCAL CACHE CONFIGURATION
|
||||
#
|
||||
# To increase performances, use a local cache for the configuration. You have
|
||||
|
@ -94,6 +96,7 @@ localStorageOptions={ 'namespace' => 'MyNamespace', 'default_expires_in' => 600,
|
|||
;portalRequireOldPassword = 1
|
||||
# Attribute displayed as connected user
|
||||
;portalUserAttr => "mail",
|
||||
|
||||
# LOG
|
||||
# By default, all is logged in Apache file. To log user actions by
|
||||
# syslog, just set syslog facility here:
|
||||
|
@ -106,6 +109,7 @@ localStorageOptions={ 'namespace' => 'MyNamespace', 'default_expires_in' => 600,
|
|||
# (http://auth.example.com/index.pl/sessions)
|
||||
# You can also restrict attributes and macros exported by getAttributes
|
||||
;exportedAttr => uid mail
|
||||
|
||||
# PASSWORD POLICY
|
||||
# Remove comment to use LDAP Password Policy
|
||||
;ldapPpolicyControl = 1
|
||||
|
@ -148,6 +152,7 @@ localStorageOptions={ 'namespace' => 'MyNamespace', 'default_expires_in' => 600,
|
|||
# cn|mail|status, where cn, mail and status will be replaced by their
|
||||
# values.
|
||||
;ldapGroupAttributeNameSearch = ['cn']
|
||||
|
||||
# NOTIFICATIONS SERVICE
|
||||
# Use it to be able to notify messages during authentication
|
||||
;notification = 1
|
||||
|
@ -165,19 +170,23 @@ localStorageOptions={ 'namespace' => 'MyNamespace', 'default_expires_in' => 600,
|
|||
# your website use Lemonldap::NG without handler with SOAP functions.
|
||||
;trustedDomains => 'my.trusted.host example2.com',
|
||||
|
||||
# Menu
|
||||
# MENU
|
||||
applicationList={ 'Menu' => { type => 'category', 'Example' => { type => 'category', 'test1' => { type => 'application', options => { name => 'Application Test 1', uri => 'http://test1.__DNSDOMAIN__/', description => 'A simple application displaying authenticated user', logo => 'wheels.png', display => 'auto', }, },'test2' => { type => 'application', options => { name => 'Application Test 2', uri => 'http://test2.__DNSDOMAIN__/', description => 'The same simple application displaying authenticated user', logo => 'wheels.png', display => 'auto', }, }, },'Administration' => { type => 'category', 'manager' => { type => 'application', options => { name => 'WebSSO Manager', uri => 'http://manager.__DNSDOMAIN__/', description => 'Configure LemonLDAP::NG WebSSO', logo => 'tools.png', display => 'on', }, },'sessions' => { type => 'application', options => { name => 'Sessions explorer', uri => 'http://manager.__DNSDOMAIN__/sessions.pl', description => 'Explore WebSSO sessions', logo => 'tools.png', display => 'on', }, }, },'Documentation' => { type => 'category', 'localdoc' => { type => 'application', options => { name => 'Local documentation', uri => 'http://manager.__DNSDOMAIN__/doc/', description => 'Documentation supplied with LemonLDAP::NG', logo => 'docs.png', display => 'on', }, },'officialwebsite' => { type => 'application', options => { name => 'Offical Website', uri => 'http://wiki.lemonldap.objectweb.org/xwiki/bin/view/NG/Presentation', description => 'Official LemonLDAP::NG Website', logo => 'web.png', display => 'on', }, }, }, }, }
|
||||
|
||||
[handler]
|
||||
# Set https to 1 if your handler protect a https website (used only for
|
||||
# redirections to the portal
|
||||
https = 0
|
||||
|
||||
# Set https to 1 if your handler protect a https website (used only for
|
||||
# redirections to the portal)
|
||||
;https = 0
|
||||
# Set port if your your hanlder protect a website on a non standard port
|
||||
# - 80 for http, 443 for https (used only for redirections ti the portal)
|
||||
;port = 8080
|
||||
# Set status to 1 if you want to have the report of activity (used for
|
||||
# example to inform MRTG)
|
||||
status = 0
|
||||
|
||||
[manager]
|
||||
|
||||
# Manager protection: by default, the manager isn't protected. You can
|
||||
# protect it :
|
||||
# * by Apache itself,
|
||||
|
@ -191,4 +200,5 @@ status = 0
|
|||
|
||||
[apply]
|
||||
|
||||
# URL used to reload configuration
|
||||
test1.__DNSDOMAIN__=http://test1.__DNSDOMAIN__/reload
|
||||
|
|
|
@ -7,12 +7,11 @@ __PACKAGE__->init(
|
|||
|
||||
# ACCESS TO CONFIGURATION
|
||||
|
||||
# By default, Lemonldap::NG uses the default lemonldap-ng.ini file to know
|
||||
# where to find is configuration
|
||||
# (generaly /etc/lemonldap-ng/lemonldap-ng.ini)
|
||||
# You can specify by yourself this file :
|
||||
#configStorage => { confFile => '/path/to/my/file' },
|
||||
|
||||
# By default, Lemonldap::NG uses the default lemonldap-ng.ini file to know
|
||||
# where to find is configuration
|
||||
# (generaly /etc/lemonldap-ng/lemonldap-ng.ini)
|
||||
# You can specify by yourself this file :
|
||||
#configStorage => { confFile => '/path/to/my/file' },
|
||||
# You can also specify directly the configuration
|
||||
# (see Lemonldap::NG::Handler::SharedConf(3))
|
||||
#configStorage => {
|
||||
|
@ -20,28 +19,6 @@ __PACKAGE__->init(
|
|||
# dirName => '/usr/local/lemonldap-ng/data/conf/'
|
||||
#},
|
||||
|
||||
# STATUS MODULE
|
||||
# Uncomment this to activate status module:
|
||||
#status => 1,
|
||||
|
||||
# REDIRECTIONS
|
||||
# You have to set this to explain to the handler if runs under SSL
|
||||
# or not (for redirections after authentications). Default is true.
|
||||
https => 0,
|
||||
|
||||
# You can also fix the port (for redirections after authentications)
|
||||
#port => 80,
|
||||
|
||||
# CROSS-DOMAIN
|
||||
# If your handler is not on the same domain than the portal, uncomment
|
||||
# this (and don't forget to set "cda => 1" in the portal
|
||||
#cda => 1,
|
||||
|
||||
# CUSTOM FUNCTION
|
||||
# If you want to create customFunctions in rules, declare them here:
|
||||
#customFunctions => 'function1 function2',
|
||||
#customFunctions => 'Package::func1 Package::func2',
|
||||
|
||||
# OTHERS
|
||||
# You can also overload any parameter issued from manager
|
||||
# configuration. Example:
|
||||
|
|
|
@ -612,18 +612,19 @@ sub conditionSub {
|
|||
sub defaultValuesInit {
|
||||
my ( $class, $args ) = splice @_;
|
||||
|
||||
# Other values
|
||||
# Warning: first start of handler load values from MyHanlder.pm
|
||||
# and lemonldap-ng.ini
|
||||
# These values should be erased by global configuration!
|
||||
$cookieName = $args->{cookieName} || $cookieName || 'lemonldap';
|
||||
$whatToTrace = $args->{whatToTrace} || $whatToTrace || 'uid';
|
||||
$whatToTrace =~ s/\$//g;
|
||||
$https = $args->{https} unless defined($https);
|
||||
$https = 1 unless defined($https);
|
||||
$https = defined($https) ? ( $https eq $args->{https} ? $https : $args->{https} ) : 1;
|
||||
$args->{securedCookie} = 1 unless defined( $args->{securedCookie} );
|
||||
$cookieName .= 'http' if ( $args->{securedCookie} == 2 and $https == 0 );
|
||||
$port = $args->{port} || 0 unless defined($port);
|
||||
$port = defined($port) ? ( $port eq $args->{port} ? $port : $args->{port} ) : 0;
|
||||
$customFunctions = $args->{customFunctions};
|
||||
$cda = $args->{cda} || 0 unless defined($cda);
|
||||
$httpOnly = $args->{httpOnly} || 1 unless defined($httpOnly);
|
||||
$cda = defined($cda) ? ( $cda eq $args->{cda} ? $cda : $args->{cda} ) : 0;
|
||||
$httpOnly = defined($httpOnly) ? ( $httpOnly eq $args->{httpOnly} ? $httpOnly : $args->{httpOnly} ) : 0;
|
||||
$cookieExpiration = $args->{cookieExpiration} || $cookieExpiration;
|
||||
1;
|
||||
}
|
||||
|
|
|
@ -351,9 +351,11 @@ sub struct {
|
|||
# OTHER PARAMETERS
|
||||
advancedParams => {
|
||||
_nodes => [
|
||||
qw(n:soap n:notifications n:passwordManagement n:security)
|
||||
qw(customFunctions n:soap n:notifications n:passwordManagement n:security n:redirection)
|
||||
],
|
||||
|
||||
customFunctions => 'text:/customFunctions',
|
||||
|
||||
soap => {
|
||||
_nodes => [qw(Soap exportedAttr trustedDomains)],
|
||||
Soap => 'bool:/Soap',
|
||||
|
@ -389,13 +391,18 @@ sub struct {
|
|||
},
|
||||
|
||||
security => {
|
||||
_nodes => [qw(https userControl portalForceAuthn)],
|
||||
https => 'bool:/https',
|
||||
_nodes => [qw(userControl portalForceAuthn)],
|
||||
userControl => 'text:/userControl:userControl:text',
|
||||
portalForceAuthn =>
|
||||
'bool:/portalForceAuthn:portalForceAuthn:bool',
|
||||
},
|
||||
|
||||
redirection => {
|
||||
_nodes => [qw(https port)],
|
||||
https => 'bool:/https',
|
||||
port => 'int:/port',
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -673,6 +680,7 @@ sub testStruct {
|
|||
test => qr/^[a-zA-Z]\w*$/,
|
||||
msgFail => 'Bad cookie name',
|
||||
},
|
||||
customFunctions => $testNotDefined,
|
||||
domain => {
|
||||
test => qr/^\.?\w+(?:\.[a-zA-Z]\w*)*(?:\.[a-zA-Z]+)$/,
|
||||
msgFail => 'Bad domain',
|
||||
|
@ -809,6 +817,10 @@ sub testStruct {
|
|||
},
|
||||
notifyDeleted => $boolean,
|
||||
notifyOther => $boolean,
|
||||
port => {
|
||||
test => qr/^\d*$/,
|
||||
msgFail => 'Bad port number'
|
||||
},
|
||||
portal => {
|
||||
test => qr/^https?:\/\/\S+$/,
|
||||
msgFail => 'Bad portal value',
|
||||
|
|
|
@ -66,6 +66,7 @@ sub en {
|
|||
cookieExpiration => 'Cookie expiration time',
|
||||
cookieName => 'Cookie Name',
|
||||
cookieParams => 'Cookies',
|
||||
customFunctions => 'Custom functions',
|
||||
databaseLocked => 'Database locked by another process',
|
||||
domain => 'Domain',
|
||||
exportedAttr => 'SOAP exported attributes',
|
||||
|
@ -117,6 +118,7 @@ sub en {
|
|||
openIdSecret => 'Secret token',
|
||||
passwordDB => 'Password module',
|
||||
passwordManagement => 'Password management',
|
||||
port => 'Port',
|
||||
portal => 'URL',
|
||||
portalAutocomplete => 'Auto complete',
|
||||
portalCustomization => 'Customization',
|
||||
|
@ -133,6 +135,7 @@ sub en {
|
|||
portalUserAttr => 'User attribute',
|
||||
proxyParams => 'Proxy parameters',
|
||||
randomPasswordRegexp => 'Regexp for password generation',
|
||||
redirection => 'Handler redirections',
|
||||
remoteCookieName => 'Cookie name',
|
||||
remoteGlobalStorage => 'Sessions module',
|
||||
remoteGlobalStorageOptions => 'Sessions module options',
|
||||
|
@ -255,6 +258,7 @@ sub fr {
|
|||
cookieExpiration => 'Durée de vie du cookie',
|
||||
cookieName => 'Nom du cookie',
|
||||
cookieParams => 'Cookies',
|
||||
customFunctions => 'Fonctions personnalisées',
|
||||
databaseLocked => 'Base de donnée verrouillée par un autre processus',
|
||||
domain => 'Domaine',
|
||||
exportedAttr => 'Attributs exportés par le portail (SOAP)',
|
||||
|
@ -306,6 +310,7 @@ sub fr {
|
|||
openIdSecret => 'Jeton secret',
|
||||
passwordDB => 'Module de mot de passe',
|
||||
passwordManagement => 'Gestion des mots de passe',
|
||||
port => 'Port',
|
||||
portal => 'URL',
|
||||
portalAutocomplete => 'Auto complétion',
|
||||
portalCustomization => 'Personnalisation',
|
||||
|
@ -322,7 +327,8 @@ sub fr {
|
|||
portalUserAttr => "Attribut de l'utilisateur",
|
||||
proxyParams => 'Paramètres Proxy',
|
||||
randomPasswordRegexp =>
|
||||
'Expression regulière pour la génération des mots-de-passe',
|
||||
'Expression regulière pour la génération des mots de passe',
|
||||
redirection => 'Redirections du Handler',
|
||||
remoteCookieName => 'Nom du cookie',
|
||||
remoteGlobalStorage => 'Module des sessions',
|
||||
remoteGlobalStorageOptions => 'Options du module des sessions',
|
||||
|
|
Loading…
Reference in New Issue