On Nov 24, 2005, at 7:59 AM, Eric Nichols wrote:
Hi Peter,
Thanks for getting back to me. My original example was wrong. The
LDIF
parser seems to be failing on any data beginning with a 'less than'
character.
Here is a better example:
dn: cn="<[EMAIL PROTECTED]",ou=site,o=org
In addition the parser seems to stop if the data of an attribute
begins with a
'<'.
sn: <doe
Well that is an error as < being the first character is supposed to
be followed by a file: URL to read the attribute contents from. But
it should not hang. $ldif->error should return an error string like
"unsupported URL type"
There have been some changes since 0.32. You can try the latest
LDIF.pm from the repository
http://svn.mutatus.co.uk/repos/perl-ldap/trunk/lib/Net/LDAP/LDIF.pm
Graham.
On Mon, November 21, 2005 12:50 pm, Peter Marschall wrote:
Hi,
On Wednesday, 16. November 2005 16:50, Eric Nichols wrote:
This one is a bit strange. I am using Net::LDAP::LDIF to process
a file.
It gets about halfway through the file and hangs up on a dn with
a less
than character in it:
dn: cn="cn=<[EMAIL PROTECTED]",ou=site,o=org
I am running .32 and did not see any ldif changes in .33..
Thoughts?
I tested the DN above with perl-ldap 0.33 using the simple LDIF
dn: cn="cn=<[EMAIL PROTECTED]",ou=site,o=org
objectClass: organizationalRole
cn: "cn=<[EMAIL PROTECTED]"
and the simple test script
#! /usr/bin/perl -w
use Net::LDAP::LDIF;
use Net::LDAP::Entry;
$in = Net::LDAP::LDIF->new('-', 'r');
while (defined(my $e = $in->read_entry())) {
$e->dump();
}
$in->done();
# EOF
and did not encunter any problems (neither in Linux i386 & Perl 5.8.7
nor in Linux x86_64 & Perl 5.8.3)
Please note that you not only have a < in the RDN, but a really
complex string
surrounded by quotes. Do you have this exact value in the cn
attribute ?
Hope it helps
Peter
--
Peter Marschall
eMail: [EMAIL PROTECTED]