question on ldap_escape_func in rlm_ldap.c

Nicolas Baradakis nbk at sitadelle.com
Wed Dec 7 14:17:49 CET 2005


Qin Zhen wrote:

> so in lastest version (1.0.5), a username 'jam\' will be converted into 
> 'jam\5c' and ldapsearch will be based on 'jam\5c' right? so this username 
> is supposed not to be found in ldap in this case?
> but how come in my server, the ldapsearch will base on 'jam' and those 
> invalid charactors r just simply eliminated? scratching head...pls 
> assist..thanks so much

That's what is said in http://www.ietf.org/rfc/rfc2254.txt

<<<<<
   If a value should contain any of the following characters

           Character       ASCII value
           ---------------------------
           *               0x2a
           (               0x28
           )               0x29
           \               0x5c
           NUL             0x00

   the character must be encoded as the backslash '\' character (ASCII
   0x5c) followed by the two hexadecimal digits representing the ASCII
   value of the encoded character. The case of the two hexadecimal
   digits is not significant.
>>>>>

-- 
Nicolas Baradakis




More information about the Freeradius-Users mailing list