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

Re: disabling special characters in ldapsearch



> I have encountered a problem with ldapsearch..following are my observations..
> 
> ldapsearch -b "o=rootdir" "(uid=kannan)"
> 
> the above search returns a success and everybody is happy..
> 
> ldapsearch -b "o=rootdir" "(uid=\kannan)"
> 
> now the above search also returns  success throwing the same result as it would
> do for the username without the \
> Has anyone come acroos this...Any sugesstions as to how to restrict such special
> characters would be great..The issue is only with \ not any other special
> character..

  You are using an special character. In Linux the \ is used to tell :"No
matter what character is the next, don't try to understand it"

  Example. Try to write in you TERM    "hello world"
  
  You MUST write:  echo "\"Hello World\""
  
  Otherwise there will be mystakens with the quotes.

> 
> I have another observation..
> 
> ldapsearch -b "o=rootdir" "(uid=*kannan)"
> 
> now with the asterix sign it seraches the entire tree which is not something
> great on a backend with a large number of records...Can i disable this too...

  The "*" is another special character. Your (open)ldap server believes you
are ordering to search "anything ended in kanan". I don't believe (99%)it can 
be disabled because it's very interesting when you don't know exactly what
are you looking for.
 

-- 
                                               Guillermo.
-----------------------------------------------------------
  ()  ascii ribbon campaign - against html mail 
  /\                        - against microsoft attachments
-----------------------------------------------------------