Hi,
Is there built-in support in Net::LDAP for escaping parameters in
search filters? Something like DBI's placeholders or at least a
method/subroutine in public API which can escape strings for me.
Example:
my $result = $ldap->search(base => $base,
filter => "uid=$user");
I want to be able to ensure that string $user is properly escaped in
search filter.
I've checked Net::LDAP docs but I haven't found anything. It seems
there is some code for escaping and de-escaping strings (subs _escape
and _unescape) for LDAP search queires in Net::LDAP::Filter but it
doesn't seem to be a part of public API so I don't think it is wise to
rely on them.
BTW it seems there is a bug in Net::LDAP::Filter docs: it is
documented to have method asn() but there is no such method in
Net::LDAP::Filter.
P.S. Please Cc replies to me as I'm not subscribed to this mailing list.
--
Ilya Martynov, [EMAIL PROTECTED]
CTO IPonWEB (UK) Ltd
Quality Perl Programming and Unix Support
UK managed @ offshore prices - http://www.iponweb.net
Personal website - http://martynov.org