From: Diffenderfer, R. <ran...@ed...> - 2001-01-17 17:00:55
|
Folks, Back when I was younger and stupider (about five minutes ago), I posted the attached message. It has been pointed out to me that the entry was exactly as expected, just "base64 encoded", as would be necessary to maintain a leading blank character! Everything works as it is supposed to. So, in the immortal words of Emily Latella, "Never mind..." :-) rnd p.s. Thanks for the library. It has made my LDAP hacking very simple and easy! > -----Original Message----- > From: Diffenderfer, Randy > Sent: Wednesday, January 17, 2001 11:33 AM > To: 'per...@li...' > Subject: perl-ldap "anomaly"? > > Folks, > > I have run across an "unexpected result" while using the perl-ldap > library, v 0.22. > > The code looks something like this... > > use Net::LDAP; > $ldap = Net::LDAP->new(...); > $entry = Net::LDAP::Entry->new(); > $entry->dn( $dn ); > $entry->add( ... > 'foo' => $foo, > ... > ); > $rc = $ldap->add( $entry ); > > What the problem is, though, is if "$foo" = " foo" (a leading blank > character), then the resulting directory entry attribute 'foo' ends up > being hosed in mysterious ways, with "bizarre" contents, e.g. "IEFxyz==" > (or something like that...). If "$foo" = "foo" (without a leading blank > character), everything works as expected. > > Can you tell me what is going on here, and whether it is "expected" or > not? > > Thank you, > Randy Diffenderfer > ran...@ed... > |