Grupos de Google ya no admite nuevas publicaciones ni suscripciones de Usenet. El contenido anterior sigue siendo visible.

using ldap, comma in dn

Visto 52 veces
Saltar al primer mensaje no leído

Jens Tekhaus

no leída,
22 jun 2009, 7:22:4622/6/09
a
In active directory from windows there is a comma in the distinguished
name of an user. When try to get it with a quoted character:
CN=name\, sname,OU=Domain_Benutzer,OU=group,DC=customer,DC=de
I get the following error message:

Invalid filter: malformed assertion value
while executing
"AssertionValue $val"
(procedure "ProcessSimpleMatch" line 3)
invoked from within
"ProcessSimpleMatch 3 $lhs $val"
(procedure "ProcessMatch" line 18)
invoked from within
"ProcessMatch $s"
(procedure "ProcessFilterComp" line 13)
invoked from within
"ProcessFilterComp [string range $s 1 end-1]"
(procedure "ProcessFilter" line 5)
invoked from within
"ProcessFilter $filter"
(procedure "ProcessFilterList" line 6)
invoked from within
"ProcessFilterList 0 [string range $s 1 end]"
(procedure "ProcessFilterComp" line 4)
invoked from within
"ProcessFilterComp $s"
(procedure "filter::encode" line 5)
invoked from within
"filter::encode $filterString"
(procedure "buildSearchRequest" line 5)
invoked from within
"buildSearchRequest $baseObject $scope $derefAliases $sizeLimit
$timeLimit $attrsOnly $filterString $attributes"
(procedure "searchInit" line 50)
invoked from within
"searchInit $handle $baseObject $filterString $attributes $args"
(procedure "::ldap::search" line 6)
invoked from within
"::ldap::search $handle [GetUserGroupFromDN $user_dn]
"&(objectCategory=user)(distinguishedName=$user_dn)" $filter"

When I tried it with users without comma in dn it works.

I tried to get it without \ and with double \. Nothing worked.

Who can help me? Thanks

Jens

schlenk

no leída,
23 jun 2009, 4:39:0623/6/09
a
Quoting for DNs is defined in http://www.faqs.org/rfcs/rfc1485.html

If that does not work, please file a bug at the sourceforge tracker
for tcllib.
http://sourceforge.net/projects/tcllib/ (category ldap)

Michael

Jens Tekhaus

no leída,
23 jun 2009, 6:54:0823/6/09
a
schlenk schrieb:

The solution is, that some charcters has to be quoted with their hex
values. I wrote a proc which substitutes the comma:

proc FixDN dn {
return [regsub -all {\\\,} $dn {\\5c\\2c}]
}

No it works.

Jens

0 mensajes nuevos