Update exportedVars for LL::NG 1.4
This commit is contained in:
parent
5f61dd75cd
commit
953d346c40
|
@ -55,10 +55,15 @@ $conf->{'locationRules'}->{"sso-manager.$domain"} = {
|
|||
} unless ($conf->{'locationRules'}->{"sso-manager.$domain"});
|
||||
|
||||
# Add default exported var
|
||||
$conf->{'exportedVars'}->{'mail'} = 'preferredMail' if ($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'});
|
||||
$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'});
|
||||
|
||||
# Remove obsolete exportedVars
|
||||
foreach my $var (qw(mail nom prenom extension)){
|
||||
delete $conf->{'exportedVars'}->{$var} if $conf->{'exportedVars'}->{$var};
|
||||
}
|
||||
|
||||
# Initialize a random key
|
||||
$conf->{'key'} = join( '', map { chr( int( rand(94) ) + 33 ) } ( 1 .. 16 ) ) unless ($conf->{'key'});
|
||||
|
|
Loading…
Reference in New Issue