Compare commits

...

4 Commits

Author SHA1 Message Date
Daniel Berteaud
743653dc5d Spec file update 2015-02-11 12:56:57 +01:00
Daniel Berteaud
74634116d2 Make sure mail exported var is set 2015-02-11 12:54:09 +01:00
Daniel Berteaud
d09770c847 Set exported variables in the global scope only
As the module specific ones are not available for HTTP headers
2015-02-11 11:59:36 +01:00
Daniel Berteaud
00d6eab43d Spec file update 2014-09-02 16:58:11 +02:00
2 changed files with 16 additions and 7 deletions

View File

@ -1,7 +1,7 @@
Summary: iPasserelle webSSO module
%define name ipasserelle-portal
Name: %{name}
%define version 0.2.5
%define version 0.2.8
%define release 1
Version: %{version}
Release: %{release}%{?dist}
@ -24,6 +24,15 @@ BuildRequires: e-smith-devtools
Add a webSSO module based on LemonLDAP::NG
%changelog
* Wed Feb 11 2015 Daniel Berteaud <daniel@firewall-services.com> 0.2.8-1
- Make sure mail var is set
* Wed Feb 11 2015 Daniel Berteaud <daniel@firewall-services.com> 0.2.7-1
- exported vars are back in the global scope
* Tue Sep 2 2014 Daniel Berteaud <daniel@firewall-services.com> 0.2.6-1
- Update exportedVars from LDAP for Lemonldap::NG 1.4
* Thu Feb 13 2014 Daniel Berteaud <daniel@firewall-services.com> 0.2.5-1
- Fix URL for hatch.gif and lock.png in CSS

View File

@ -55,14 +55,14 @@ $conf->{'locationRules'}->{"sso-manager.$domain"} = {
} unless ($conf->{'locationRules'}->{"sso-manager.$domain"});
# Add default exported var
$conf->{'ldapExportedVars'}->{'mail'} = 'preferredMail' if ($conf->{'ldapExportedVars'}->{'mail'} eq 'mail');
$conf->{'ldapExportedVars'}->{'extension'} = 'extensionNumber' unless ($conf->{'ldapExportedVars'}->{'extension'});
$conf->{'ldapExportedVars'}->{'nom'} = 'sn' unless ($conf->{'ldapExportedVars'}->{'nom'});
$conf->{'ldapExportedVars'}->{'prenom'} = 'givenName' unless ($conf->{'ldapExportedVars'}->{'prenom'});
$conf->{'exportedVars'}->{'mail'} = 'preferredMail' if (!$conf->{'exportedVars'}->{'mail'} || $conf->{'exportedVars'}->{'mail'} eq 'mail');
$conf->{'exportedVars'}->{'extension'} = 'extensionNumber' unless ($conf->{'exportedVars'}->{'extension'});
$conf->{'exportedVars'}->{'nom'} = 'sn' unless ($conf->{'exportedVars'}->{'nom'});
$conf->{'exportedVars'}->{'prenom'} = 'givenName' unless ($conf->{'exportedVars'}->{'prenom'});
# Remove obsolete exportedVars
# Remove ldapExportedVars which conflicts with exportedVars
foreach my $var (qw(mail nom prenom extension)){
delete $conf->{'exportedVars'}->{$var} if $conf->{'exportedVars'}->{$var};
delete $conf->{'ldapExportedVars'}->{$var} if ($conf->{'ldapExportedVars'}->{$var} && $conf->{'exportedVars'}->{$var});
}
# Initialize a random key