projects
/
licom.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Change the layout assumed on the LDAP server.
[licom.git]
/
lib
/
LiCoM
/
Person.pm
diff --git
a/lib/LiCoM/Person.pm
b/lib/LiCoM/Person.pm
index
4ba1be4
..
3c43a4b
100644
(file)
--- a/
lib/LiCoM/Person.pm
+++ b/
lib/LiCoM/Person.pm
@@
-165,8
+165,8
@@
sub create
return (undef);
}
return (undef);
}
- $
dn = "cn=$sn $gn," . get_config ('base_dn')
;
-
($ou) = get_config ('base_dn') =~ m/\bou\s*=\s*([^,]+)/i
;
+ $
ou = 'Person'
;
+
$dn = "cn=$sn $gn,ou=$ou," . get_config ('base_dn')
;
$entry->add (cn => "$sn $gn", ou => $ou);
$entry->dn ($dn);
$entry->add (cn => "$sn $gn", ou => $ou);
$entry->dn ($dn);
@@
-257,7
+257,7
@@
sub search
$mesg = $Ldap->search
(
$mesg = $Ldap->search
(
- base => get_config ('base_dn'),
+ base =>
'ou=Person,' .
get_config ('base_dn'),
filter => $filter
);
filter => $filter
);
@@
-297,7
+297,7
@@
sub get_user
my $mesg = $Ldap->search
(
my $mesg = $Ldap->search
(
- base => get_config ('base_dn'),
+ base =>
'ou=Person,' .
get_config ('base_dn'),
filter => "(cn=$search)"
);
filter => "(cn=$search)"
);
@@
-360,7
+360,7
@@
sub _update_dn
my $sn = $obj->{'sn'};
my $gn = $obj->{'givenName'};
my $cn = "$sn $gn";
my $sn = $obj->{'sn'};
my $gn = $obj->{'givenName'};
my $cn = "$sn $gn";
- my $dn = "cn=$cn," . get_config ('base_dn');
+ my $dn = "cn=$cn,
ou=Person,
" . get_config ('base_dn');
$obj->{'cn'} = $cn;
$obj->{'cn'} = $cn;