From: Bob G. <Bob...@kp...> - 2001-10-16 19:31:46
|
I ran across an oddity in Net::LDAP (I think). When I request the attributes for an object, if an attribute has an alias, I get the attribute name for some attributes and the alias name for others. This code snippet illustrates my problem: my $ent = $msg ->shift_entry(); my @attrs = ($ent -> attributes()); foreach my $i (@attrs ) { $val = $ent -> get_value($i); print ("$i -- $val\n"); } Prints -- objectClass -- top cn -- Alex Y Young sn -- Young givenName -- Alex uid -- 2 My OID table data definitions: commonName,cn: attributeType.3 :,Y : :name surname,sn: attributeType.4 :,Y : :name givenName,gn: attributeType.42 : ::name userid,uid: pilotAttributeType.1 :CaseIgnoreString Why do I get "givenName" and not "gn"; "sn" and not "surname"? Why does $ent -> get_value("uid") return "2"; but $ent -> get_value("userid") returns undef? What piece am I missing here? I am also posting this off to the vendor of my LDAP server (Syntegra), to see what they can come up with. Bob G bob...@kp... |