[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: equal character forbidden in DN

Harms, Hendrik (EXTERN: TOJAQ) wrote:
My old openldap-2.1.26 accepts DNs with the '=' character in it. My
openldap-2.1.29 doesn't:

Example "dn: Document=254 Page=1-2,ou=data,dc=MyCompany"

You could use

perl -pe '1 while /^dn:/ and s/(=[^,]*[^\\,])=/$1\\=/'

to convert your data:

dn: Document=254 Page=1-2,ou=data,dc=MyCompany
dn: Document=254 Page\=1-2,ou=data,dc=MyCompany

(This presumes no element of your DN name does not start with an equals sign; "dn: dc==yes" would not be translated to "dn: dc=\=yes".)

           John Borwick
       Systems Administrator
      Wake Forest University | web  http://www.wfu.edu/~borwicjh
      Winston-Salem, NC, USA | GPG key ID               56D60872

Attachment: signature.asc
Description: OpenPGP digital signature