Compare commits
64 Commits
master
...
pkg/eole/e
Author | SHA1 | Date | |
---|---|---|---|
283da1353a | |||
95b8facd7e | |||
f3af0400d9 | |||
1535f7c8ef | |||
ae88bb7602 | |||
195484f1fb | |||
cc637b2c7e | |||
1c91addc6d | |||
e5afd4ccff | |||
34239e8ce5 | |||
ad8e4a69a9 | |||
|
5c7a9f9894 | ||
|
8d3f12de72 | ||
|
c7d4949fb7 | ||
|
6890500d5b | ||
|
2355b20c7d | ||
|
2ac6c9158f | ||
|
c9c23aaa69 | ||
|
26ddf79a97 | ||
|
11c83c8d92 | ||
|
dd242a3c5a | ||
|
bd8403b610 | ||
eb15ad0846 | |||
22f5af608e | |||
667384db1f | |||
01d1cb3811 | |||
26d696d6f8 | |||
11aca56f4e | |||
85f8f7b079 | |||
2d8082913c | |||
a53fe39db1 | |||
44ee4421c1 | |||
24a5264933 | |||
f5631ff980 | |||
c9eebbb0a5 | |||
c7c5f08b7a | |||
889010cfe7 | |||
f0d6325cf5 | |||
3b4d3ccb41 | |||
66be6dc37e | |||
08ed6a21dc | |||
faf2a361db | |||
7ae579b670 | |||
baa4dca9de | |||
849c3f0a88 | |||
6f1cb45eac | |||
4916317d30 | |||
b7556a03b8 | |||
f1defd2626 | |||
7269e252de | |||
9e64f5ca8d | |||
84f41d0196 | |||
b90eb474f5 | |||
d69f20c896 | |||
658013c177 | |||
35edad1538 | |||
32d336e37b | |||
4b26fc5c38 | |||
904abd02a4 | |||
e2f656f9f8 | |||
e5ada4d3eb | |||
dab8085a83 | |||
ad490d3810 | |||
0fc774cd05 |
4
.gitignore
vendored
4
.gitignore
vendored
@ -1,4 +0,0 @@
|
|||||||
# Backup and swap files
|
|
||||||
*~
|
|
||||||
*#
|
|
||||||
*.swp
|
|
6
Makefile
6
Makefile
@ -3,9 +3,9 @@
|
|||||||
################################
|
################################
|
||||||
|
|
||||||
SOURCE=eole-lemonldap
|
SOURCE=eole-lemonldap
|
||||||
VERSION=0.1
|
VERSION=2.8.0
|
||||||
EOLE_VERSION=2.7
|
EOLE_VERSION=2.8
|
||||||
EOLE_RELEASE=2.7.2
|
EOLE_RELEASE=2.8.0
|
||||||
PKGAPPS=non
|
PKGAPPS=non
|
||||||
#FLASK_MODULE=<APPLICATION>
|
#FLASK_MODULE=<APPLICATION>
|
||||||
|
|
||||||
|
21
README.md
21
README.md
@ -4,27 +4,6 @@ LemonLDAP::NG EOLE integration
|
|||||||
|
|
||||||
## Howto
|
## Howto
|
||||||
|
|
||||||
### Repository configuration
|
|
||||||
|
|
||||||
* Add the lemonldap-ng deb respository we need the last version of LemonLDAP.
|
|
||||||
|
|
||||||
GenConfig -> Mode Expert -> Dépôts tiers -> Libellé du dépôt
|
|
||||||
|
|
||||||
#### LemonLDAP::NG repository (if you use EOLE 2.8.X this is not needed anymore)
|
|
||||||
|
|
||||||
* deb https://lemonldap-ng.org/deb stable main
|
|
||||||
* deb-src https://lemonldap-ng.org/deb stable main
|
|
||||||
* Key URL : https://lemonldap-ng.org/_media/rpm-gpg-key-ow2
|
|
||||||
|
|
||||||
#### Cadoles Repository
|
|
||||||
* deb [ arch=all ] https://vulcain.cadoles.com 2.7.2-dev main
|
|
||||||
* Key URL : https://vulcain.cadoles.com/cadoles.gpg
|
|
||||||
|
|
||||||
### Install packages
|
|
||||||
|
|
||||||
apt update
|
|
||||||
apt install eole-lemonldap
|
|
||||||
|
|
||||||
### Configure LemonLDAP in GenConfig
|
### Configure LemonLDAP in GenConfig
|
||||||
|
|
||||||
* Enable lemonldap in "Services" tab
|
* Enable lemonldap in "Services" tab
|
||||||
|
54
debian/control
vendored
Normal file
54
debian/control
vendored
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
Source: eole-lemonldap-ng
|
||||||
|
Section: web
|
||||||
|
Priority: optional
|
||||||
|
Maintainer: Équipe EOLE <eole@ac-dijon.fr>
|
||||||
|
Build-Depends: debhelper-compat (= 12)
|
||||||
|
Standards-Version: 4.5.0
|
||||||
|
Homepage: https://dev-eole.ac-dijon.fr/projects/sso
|
||||||
|
Vcs-Git: https://dev-eole.ac-dijon.fr/git/eole-lemonldap-ng.git
|
||||||
|
Vcs-Browser: https://dev-eole.ac-dijon.fr/projects/sso/repository
|
||||||
|
|
||||||
|
Package: eole-lemonldap-ng
|
||||||
|
Architecture: all
|
||||||
|
Depends: eole-lemonldap-ng-pkg,
|
||||||
|
${misc:Depends}
|
||||||
|
Description: Dictionnaires et templates pour la configuration d'un serveur LemonLDAP::NG
|
||||||
|
Pour toute information complémentaire, veuillez vous rendre sur le
|
||||||
|
site du projet EOLE.
|
||||||
|
|
||||||
|
Package: eole-lemonldap-ng-scribe
|
||||||
|
Architecture: all
|
||||||
|
Depends: eole-scribe,
|
||||||
|
eole-lemonldap-ng,
|
||||||
|
libapache2-mod-perl2,
|
||||||
|
${misc:Depends}
|
||||||
|
Description: Dictionnaire pour calculer les valeurs automatiquement sur Scribe
|
||||||
|
.
|
||||||
|
Pour toute information complémentaire, veuillez vous rendre sur le
|
||||||
|
site du projet EOLE.
|
||||||
|
|
||||||
|
Package: eole-lemonldap-ng-pkg
|
||||||
|
Architecture: all
|
||||||
|
Section: metapackages
|
||||||
|
Depends: lemonldap-ng,
|
||||||
|
lemonldap-ng-doc,
|
||||||
|
lemonldap-ng-fastcgi-server,
|
||||||
|
lemonldap-ng-handler,
|
||||||
|
liblemonldap-ng-handler-perl,
|
||||||
|
liblemonldap-ng-manager-perl,
|
||||||
|
liblemonldap-ng-portal-perl,
|
||||||
|
libauthen-captcha-perl,
|
||||||
|
libauthen-sasl-perl,
|
||||||
|
libemail-sender-perl,
|
||||||
|
libgd-securityimage-perl,
|
||||||
|
libimage-magick-perl,
|
||||||
|
libio-string-perl,
|
||||||
|
liblasso-perl,
|
||||||
|
libnet-ldap-perl,
|
||||||
|
libunicode-string-perl,
|
||||||
|
libmime-tools-perl,
|
||||||
|
libnet-openid-server-perl,
|
||||||
|
${misc:Depends}
|
||||||
|
Description: Paquet de dépendances pour eole-lemonldap.
|
||||||
|
.
|
||||||
|
Pour toute information complémentaire, veuillez vous rendre sur la forge Cadoles.
|
37
debian/copyright
vendored
Normal file
37
debian/copyright
vendored
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
||||||
|
Upstream-Name: eole-lemonldap-ng
|
||||||
|
Source: http://dev-eole.ac-dijon.fr/projects/sso
|
||||||
|
|
||||||
|
Files: *
|
||||||
|
Copyright: 2020 Équipe EOLE <eole@ac-dijon.fr>
|
||||||
|
License: CeCILL-C
|
||||||
|
|
||||||
|
License: CeCILL-C
|
||||||
|
This software is governed by the CeCILL-C license under French law and
|
||||||
|
abiding by the rules of distribution of free software. You can use,
|
||||||
|
modify and or redistribute the software under the terms of the CeCILL-C
|
||||||
|
license as circulated by CEA, CNRS and INRIA at the following URL
|
||||||
|
"http://www.cecill.info";.
|
||||||
|
.
|
||||||
|
As a counterpart to the access to the source code and rights to copy,
|
||||||
|
modify and redistribute granted by the license, users are provided only
|
||||||
|
with a limited warranty and the software's author, the holder of the
|
||||||
|
economic rights, and the successive licensors have only limited
|
||||||
|
liability.
|
||||||
|
.
|
||||||
|
In this respect, the user's attention is drawn to the risks associated
|
||||||
|
with loading, using, modifying and/or developing or reproducing the
|
||||||
|
software by the user in light of its specific status of free software,
|
||||||
|
that may mean that it is complicated to manipulate, and that also
|
||||||
|
therefore means that it is reserved for developers and experienced
|
||||||
|
professionals having in-depth computer knowledge. Users are therefore
|
||||||
|
encouraged to load and test the software's suitability as regards their
|
||||||
|
requirements in conditions enabling the security of their systems and/or
|
||||||
|
data to be ensured and, more generally, to use and operate it in the
|
||||||
|
same conditions as regards security.
|
||||||
|
.
|
||||||
|
The fact that you are presently reading this means that you have had
|
||||||
|
knowledge of the CeCILL-C license and that you accept its terms.
|
||||||
|
.
|
||||||
|
On Eole systems, the complete text of the CeCILL-C License can be found
|
||||||
|
in `/usr/share/common-licenses/CeCILL-2'.
|
2
debian/eole-lemonldap-ng-scribe.install
vendored
Normal file
2
debian/eole-lemonldap-ng-scribe.install
vendored
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
usr/share/eole/creole/dicos/71_lemonldap_ng_scribe.xml
|
||||||
|
usr/share/eole/postservice/98-lemonldap-ng-scribe-register-hosts
|
6
debian/eole-lemonldap-ng.install
vendored
Normal file
6
debian/eole-lemonldap-ng.install
vendored
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
usr/share/creole/
|
||||||
|
usr/share/eole/creole/dicos/70_lemonldap_ng.xml
|
||||||
|
usr/share/eole/creole/distrib/
|
||||||
|
usr/share/eole/diagnose/
|
||||||
|
usr/share/eole/postservice/99-lemonldap-ng
|
||||||
|
usr/share/eole/posttemplate/
|
3
debian/gbp.conf
vendored
Normal file
3
debian/gbp.conf
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
# Set per distribution debian tag
|
||||||
|
[DEFAULT]
|
||||||
|
debian-tag = debian/eole/%(version)s
|
9
debian/rules
vendored
Executable file
9
debian/rules
vendored
Executable file
@ -0,0 +1,9 @@
|
|||||||
|
#!/usr/bin/make -f
|
||||||
|
# -*- makefile -*-
|
||||||
|
|
||||||
|
# Uncomment this to turn on verbose mode.
|
||||||
|
export DH_VERBOSE=1
|
||||||
|
export DH_OPTIONS=-v
|
||||||
|
|
||||||
|
%:
|
||||||
|
dh $@
|
1
debian/source/format
vendored
Normal file
1
debian/source/format
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
3.0 (native)
|
@ -24,6 +24,9 @@
|
|||||||
<target type='variable'>activer_sso</target>
|
<target type='variable'>activer_sso</target>
|
||||||
</condition>
|
</condition>
|
||||||
|
|
||||||
|
<auto name='calc_val' target='ldapScheme'>
|
||||||
|
<param>ldaps</param>
|
||||||
|
</auto>
|
||||||
|
|
||||||
<fill name='calc_val_first_value' target='eolesso_adresse'>
|
<fill name='calc_val_first_value' target='eolesso_adresse'>
|
||||||
<param type='eole' optional='True' hidden='False'>authWebName</param>
|
<param type='eole' optional='True' hidden='False'>authWebName</param>
|
||||||
@ -31,24 +34,21 @@
|
|||||||
<param type='eole'>nom_domaine_machine</param>
|
<param type='eole'>nom_domaine_machine</param>
|
||||||
</fill>
|
</fill>
|
||||||
|
|
||||||
|
<auto name='calc_val' target='ldap_port'>
|
||||||
|
<param>389</param>
|
||||||
|
</auto>
|
||||||
|
|
||||||
<condition name='frozen_if_in' source='activerLemon'>
|
<condition name='frozen_if_in' source='activerLemon'>
|
||||||
<param>oui</param>
|
<param>oui</param>
|
||||||
<target type='variable'>eolesso_adresse</target>
|
<target type='variable'>eolesso_adresse</target>
|
||||||
</condition>
|
</condition>
|
||||||
|
|
||||||
<auto name='calc_multi_condition' target='ldapScheme'>
|
|
||||||
<param>oui</param>
|
|
||||||
<param type='eole' name='condition_1'>ldap_tls</param>
|
|
||||||
<param name='match'>ldaps</param>
|
|
||||||
<param name='default_mismatch'>ldap</param>
|
|
||||||
</auto>
|
|
||||||
|
|
||||||
<auto name='calc_val' target='ldapServer'>
|
<auto name='calc_val' target='ldapServer'>
|
||||||
<param type='eole'>adresse_ip_ldap</param>
|
<param type='eole'>ad_address</param>
|
||||||
</auto>
|
</auto>
|
||||||
|
|
||||||
<auto name='calc_val' target='ldapServerPort'>
|
<auto name='calc_val' target='ldapServerPort'>
|
||||||
<param type='eole'>ldap_port</param>
|
<param type='number'>389</param>
|
||||||
</auto>
|
</auto>
|
||||||
|
|
||||||
<auto name='calc_val' target='lemon_user_db'>
|
<auto name='calc_val' target='lemon_user_db'>
|
||||||
@ -62,11 +62,11 @@
|
|||||||
<param type='eole'>ldap_base_dn</param>
|
<param type='eole'>ldap_base_dn</param>
|
||||||
</auto>
|
</auto>
|
||||||
<auto name='calc_val' target='ldapBindUserDN'>
|
<auto name='calc_val' target='ldapBindUserDN'>
|
||||||
<param type='eole'>ldap_reader</param>
|
<param type='eole'>sasl_ldap_reader</param>
|
||||||
</auto>
|
</auto>
|
||||||
|
|
||||||
<auto name='calc_val' target='ldapBindUserPassword'>
|
<auto name='calc_val' target='ldapBindUserPassword'>
|
||||||
<param type='eole'>ldap_reader_passfile</param>
|
<param>/etc/eole/private/sasl-reader.password</param>
|
||||||
</auto>
|
</auto>
|
||||||
|
|
||||||
<auto name='calc_val' target='casFolder'>
|
<auto name='calc_val' target='casFolder'>
|
||||||
@ -77,4 +77,4 @@
|
|||||||
|
|
||||||
<help />
|
<help />
|
||||||
|
|
||||||
</creole>
|
</creole>
|
||||||
|
@ -1,2 +0,0 @@
|
|||||||
creolefuncs_DATA_DIR := $(DESTDIR)/usr/share/creole/funcs
|
|
||||||
lemonldap-ng_DATA_DIR := $(eole_DIR)/lemonldap-ng
|
|
1
eole-lemonldap.mk
Normal file
1
eole-lemonldap.mk
Normal file
@ -0,0 +1 @@
|
|||||||
|
creolefuncs_DATA_DIR := $(DESTDIR)/usr/share/creole/funcs
|
@ -1,102 +0,0 @@
|
|||||||
package Lemonldap::NG::Portal::UserDB::LDAP;
|
|
||||||
|
|
||||||
use strict;
|
|
||||||
use Mouse;
|
|
||||||
use utf8;
|
|
||||||
use Lemonldap::NG::Portal::Main::Constants qw(PE_OK);
|
|
||||||
|
|
||||||
extends 'Lemonldap::NG::Portal::Lib::LDAP';
|
|
||||||
|
|
||||||
our $VERSION = '2.0.6';
|
|
||||||
|
|
||||||
has ldapGroupAttributeNameSearch => (
|
|
||||||
is => 'rw',
|
|
||||||
lazy => 1,
|
|
||||||
builder => sub {
|
|
||||||
my $attributes = [];
|
|
||||||
@$attributes =
|
|
||||||
split( /\s+/, $_[0]->{conf}->{ldapGroupAttributeNameSearch} )
|
|
||||||
if $_[0]->{conf}->{ldapGroupAttributeNameSearch};
|
|
||||||
push( @$attributes, $_[0]->{conf}->{ldapGroupAttributeNameGroup} )
|
|
||||||
if ( $_[0]->{conf}->{ldapGroupRecursive}
|
|
||||||
and $_[0]->{conf}->{ldapGroupAttributeNameGroup} ne "dn" );
|
|
||||||
return $attributes;
|
|
||||||
}
|
|
||||||
);
|
|
||||||
|
|
||||||
# RUNNING METHODS
|
|
||||||
#
|
|
||||||
# getUser is provided by Portal::Lib::LDAP
|
|
||||||
|
|
||||||
# Load all parameters included in exportedVars parameter.
|
|
||||||
# Multi-value parameters are loaded in a single string with
|
|
||||||
# a separator (param multiValuesSeparator)
|
|
||||||
# @return Lemonldap::NG::Portal constant
|
|
||||||
sub setSessionInfo {
|
|
||||||
my ( $self, $req ) = @_;
|
|
||||||
$req->{sessionInfo}->{_dn} = $req->data->{dn};
|
|
||||||
|
|
||||||
my %vars = ( %{ $self->conf->{exportedVars} },
|
|
||||||
%{ $self->conf->{ldapExportedVars} } );
|
|
||||||
while ( my ( $k, $v ) = each %vars ) {
|
|
||||||
|
|
||||||
# getLdapValue returns an empty string for missing attribute
|
|
||||||
# but we really want to return undef so they don't get stored in session
|
|
||||||
$req->sessionInfo->{$k} =
|
|
||||||
$self->ldap->getLdapValue( $req->data->{ldapentry}, $v ) || undef;
|
|
||||||
}
|
|
||||||
|
|
||||||
PE_OK;
|
|
||||||
}
|
|
||||||
|
|
||||||
# Load all groups in $groups.
|
|
||||||
# @return Lemonldap::NG::Portal constant
|
|
||||||
sub setGroups {
|
|
||||||
my ( $self, $req ) = @_;
|
|
||||||
my $groups = $req->{sessionInfo}->{groups};
|
|
||||||
my $hGroups = $req->{sessionInfo}->{hGroups};
|
|
||||||
|
|
||||||
if ( $self->conf->{ldapGroupBase} ) {
|
|
||||||
|
|
||||||
# Get value for group search
|
|
||||||
my $group_value = $self->ldap->getLdapValue( $req->data->{ldapentry},
|
|
||||||
$self->conf->{ldapGroupAttributeNameUser} );
|
|
||||||
|
|
||||||
if ( $self->conf->{ldapGroupDecodeSearchedValue} ) {
|
|
||||||
utf8::decode($group_value);
|
|
||||||
}
|
|
||||||
|
|
||||||
$self->logger->debug( "Searching LDAP groups in "
|
|
||||||
. $self->conf->{ldapGroupBase}
|
|
||||||
. " for $group_value" );
|
|
||||||
|
|
||||||
# Call searchGroups
|
|
||||||
my $ldapGroups = $self->ldap->searchGroups(
|
|
||||||
$self->conf->{ldapGroupBase},
|
|
||||||
$self->conf->{ldapGroupAttributeName},
|
|
||||||
$group_value,
|
|
||||||
$self->ldapGroupAttributeNameSearch,
|
|
||||||
$req->{ldapGroupDuplicateCheck}
|
|
||||||
);
|
|
||||||
|
|
||||||
foreach ( keys %$ldapGroups ) {
|
|
||||||
my $groupName = $_;
|
|
||||||
$hGroups->{$groupName} = $ldapGroups->{$groupName};
|
|
||||||
my $groupValues = [];
|
|
||||||
foreach ( @{ $self->ldapGroupAttributeNameSearch } ) {
|
|
||||||
next if $_ =~ /^name$/;
|
|
||||||
my $firstValue = $ldapGroups->{$groupName}->{$_}->[0];
|
|
||||||
push @$groupValues, $firstValue;
|
|
||||||
}
|
|
||||||
$groups .= $self->conf->{multiValuesSeparator} if $groups;
|
|
||||||
$groups .= join( '|', @$groupValues );
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
$req->{sessionInfo}->{groups} = $groups;
|
|
||||||
$req->{sessionInfo}->{hGroups} = $hGroups;
|
|
||||||
PE_OK;
|
|
||||||
}
|
|
||||||
|
|
||||||
1;
|
|
@ -1,20 +0,0 @@
|
|||||||
--- /usr/share/perl5/Lemonldap/NG/Portal/UserDB/LDAP.pm.old 2019-12-11 12:05:54.000000000 +0100
|
|
||||||
+++ /usr/share/perl5/Lemonldap/NG/Portal/UserDB/LDAP.pm 2021-01-05 10:54:19.188732119 +0100
|
|
||||||
@@ -40,10 +40,15 @@
|
|
||||||
%{ $self->conf->{ldapExportedVars} } );
|
|
||||||
while ( my ( $k, $v ) = each %vars ) {
|
|
||||||
|
|
||||||
+ my $value = $self->ldap->getLdapValue( $req->data->{ldapentry}, $v );
|
|
||||||
+
|
|
||||||
# getLdapValue returns an empty string for missing attribute
|
|
||||||
# but we really want to return undef so they don't get stored in session
|
|
||||||
- $req->sessionInfo->{$k} =
|
|
||||||
- $self->ldap->getLdapValue( $req->data->{ldapentry}, $v ) || undef;
|
|
||||||
+ # This has to be a string comparison because "0" is a valid attribute
|
|
||||||
+ # value. See #2403
|
|
||||||
+ $value = undef if ( $value eq "" );
|
|
||||||
+
|
|
||||||
+ $req->sessionInfo->{$k} = $value;
|
|
||||||
}
|
|
||||||
|
|
||||||
PE_OK;
|
|
@ -1,12 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
[ "$(CreoleGet activerLemon non)" = 'oui' ] || exit 0
|
||||||
[[ $(CreoleGet activerLemon non) == "non" ]] && exit 0
|
|
||||||
|
|
||||||
# Updating Configuration cache
|
|
||||||
|
|
||||||
cmd="/usr/share/lemonldap-ng/bin/lemonldap-ng-cli update-cache"
|
|
||||||
opt="update-cache"
|
|
||||||
|
|
||||||
# Updating Configuration cache
|
# Updating Configuration cache
|
||||||
/usr/share/lemonldap-ng/bin/lemonldap-ng-cli update-cache 2>&1
|
/usr/share/lemonldap-ng/bin/lemonldap-ng-cli update-cache 2>&1
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# vérifie si le patch est déjà appliqué
|
|
||||||
grep -q 2403 /usr/share/perl5/Lemonldap/NG/Portal/UserDB/LDAP.pm && exit 0
|
|
||||||
|
|
||||||
# copie de sauvegarde
|
|
||||||
cp -a /usr/share/perl5/Lemonldap/NG/Portal/UserDB/LDAP.pm /usr/share/eole/lemonldap-ng/
|
|
||||||
|
|
||||||
# application du patch
|
|
||||||
patch -d / -p 0 < /usr/share/eole/lemonldap-ng/LDAP.pm.patch
|
|
||||||
|
|
||||||
exit 0
|
|
@ -36,7 +36,7 @@
|
|||||||
;
|
;
|
||||||
; 1 - Defined logging level
|
; 1 - Defined logging level
|
||||||
; Set here one of error, warn, notice, info or debug
|
; Set here one of error, warn, notice, info or debug
|
||||||
logLevel = %%lm_loglevel
|
logLevel = debug
|
||||||
; Note that this has no effect for Apache2 logging: Apache LogLevel is used
|
; Note that this has no effect for Apache2 logging: Apache LogLevel is used
|
||||||
; instead
|
; instead
|
||||||
;
|
;
|
||||||
@ -65,9 +65,9 @@ logLevel = %%lm_loglevel
|
|||||||
; 2.1 - Using Syslog
|
; 2.1 - Using Syslog
|
||||||
;
|
;
|
||||||
; For Syslog logging, you can also overwrite facilities. Default values:
|
; For Syslog logging, you can also overwrite facilities. Default values:
|
||||||
logger = Lemonldap::NG::Common::Logger::Syslog
|
;logger = Lemonldap::NG::Common::Logger::Syslog
|
||||||
syslogFacility = daemon
|
;syslogFacility = daemon
|
||||||
userSyslogFacility = auth
|
;userSyslogFacility = auth
|
||||||
;
|
;
|
||||||
; 2.2 - Using Log4perl
|
; 2.2 - Using Log4perl
|
||||||
;
|
;
|
||||||
|
@ -1,25 +1,17 @@
|
|||||||
%set %%boolean = {'oui': 1, 'non': 0}
|
%set %%boolean = {'oui': 1, 'non': 0}
|
||||||
%set %%ssoFilters = %%getSSOFilters
|
%set %%ssoFilters = %%getSSOFilters
|
||||||
%set %%ldapAttributes = {"uid": "uid", "mail": "mail", "cn":"cn"}
|
|
||||||
%set %%exported_vars = ['"UA": "HTTP_USER_AGENT"']
|
%set %%exported_vars = ['"UA": "HTTP_USER_AGENT"']
|
||||||
%set %%cas_attributes = []
|
%set %%cas_attributes = []
|
||||||
%set %%ldap_attributes = {}
|
|
||||||
%for %%attr in %%casAttribute
|
%for %%attr in %%casAttribute
|
||||||
%silent %%exported_vars.append('"' + %%attr + '": "' + %%attr.casLDAPAttribute + '"')
|
%silent %%exported_vars.append('"' + %%attr + '": "' + %%attr + '.casLDAPAttribute"')
|
||||||
%silent %%cas_attributes.append('"' + %%attr + '": "' + %%attr.casLDAPAttribute + '"')
|
%silent %%cas_attributes.append('"' + %%attr + '": "' + %%attr + '.casLDAPAttribute"')
|
||||||
%set %%ldap_attributes[%%attr.casLDAPAttribute] = %%attr.casLDAPAttribute
|
|
||||||
%end for
|
%end for
|
||||||
%for %%key, %%value in %%ssoFilters
|
%for %%key, %%value in %%ssoFilters
|
||||||
%silent %%exported_vars.append('"' + %%key + '": "' + %%value + '"')
|
%silent %%exported_vars.append('"' + %%key + '": "' + %%value + '"')
|
||||||
%silent %%cas_attributes.append('"' + %%key + '": "' + %%value + '"')
|
%silent %%cas_attributes.append('"' + %%key + '": "' + %%value + '"')
|
||||||
%set %%ldap_attributes[%%value] = %%value
|
|
||||||
%end for
|
%end for
|
||||||
%silent %%exported_vars.sort()
|
%silent %%exported_vars.sort()
|
||||||
%silent %%cas_attributes.sort()
|
%silent %%cas_attributes.sort()
|
||||||
%set %%ldapAttr = []
|
|
||||||
%for %%k, %%v in %%ldap_attributes.items()
|
|
||||||
%silent %%ldapAttr.append('"' + %%k + '": "' + %%v + '"')
|
|
||||||
%end for
|
|
||||||
{
|
{
|
||||||
%if %%lemon_user_db == "AD"
|
%if %%lemon_user_db == "AD"
|
||||||
"ADPwdExpireWarning": %%llADPasswordExpireWarn,
|
"ADPwdExpireWarning": %%llADPasswordExpireWarn,
|
||||||
@ -181,7 +173,9 @@
|
|||||||
"ldapSearchDeref": "find",
|
"ldapSearchDeref": "find",
|
||||||
"ldapBase": "%%ldapUserBaseDN",
|
"ldapBase": "%%ldapUserBaseDN",
|
||||||
"ldapExportedVars": {
|
"ldapExportedVars": {
|
||||||
%%custom_join(%%ldapAttr, ',\n ')
|
"cn": "cn",
|
||||||
|
"mail": "mail",
|
||||||
|
"uid": "uid"
|
||||||
},
|
},
|
||||||
"ldapGroupAttributeName": "memberUid",
|
"ldapGroupAttributeName": "memberUid",
|
||||||
"ldapGroupAttributeNameGroup": "dn",
|
"ldapGroupAttributeNameGroup": "dn",
|
||||||
@ -196,9 +190,9 @@
|
|||||||
"ldapServer": "%%ldapScheme://%%ldapServer",
|
"ldapServer": "%%ldapScheme://%%ldapServer",
|
||||||
%if %%ldapScheme == "ldaps"
|
%if %%ldapScheme == "ldaps"
|
||||||
%if %%lmldapverify == "oui"
|
%if %%lmldapverify == "oui"
|
||||||
"ldapVerify": "Require",
|
"ldapVerify": "required",
|
||||||
%else
|
%else
|
||||||
"ldapVerify": "None",
|
"ldapVerify": "none",
|
||||||
%end if
|
%end if
|
||||||
%end if
|
%end if
|
||||||
"ldapSetPassword": 0,
|
"ldapSetPassword": 0,
|
||||||
@ -285,7 +279,7 @@
|
|||||||
"portalDisplayChangePassword": "$_auth =~ /^(AD|LDAP|DBI|Demo)$/",
|
"portalDisplayChangePassword": "$_auth =~ /^(AD|LDAP|DBI|Demo)$/",
|
||||||
"portalDisplayLoginHistory": 1,
|
"portalDisplayLoginHistory": 1,
|
||||||
"portalDisplayLogout": 1,
|
"portalDisplayLogout": 1,
|
||||||
"portalDisplayRegister": %%boolean[%%llRegisterAccount],
|
"portalDisplayRegister": 1,
|
||||||
"portalDisplayResetPassword": %%boolean[%%llResetPassword],
|
"portalDisplayResetPassword": %%boolean[%%llResetPassword],
|
||||||
"portalForceAuthn": 0,
|
"portalForceAuthn": 0,
|
||||||
"portalForceAuthnInterval": 0,
|
"portalForceAuthnInterval": 0,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user