Hi Graham, using smaller junks of data solves the problem! Thank you very much! It solved the problem on both AD and OpenLDAP and sending smaller junks of data seems generally to be a good idea.
Cheers, Swen -----Ursprüngliche Nachricht----- Von: Graham Barr [mailto:[EMAIL PROTECTED] Gesendet: Samstag, 2. Juni 2007 01:41 An: Jozef Kutej Cc: Vermeul Swen; perl-ldap@perl.org Betreff: Re: Net::LDAPS - problems with big entries I guess the first thing is to determine exactly where it is hanging. I cannot reproduce the problem myself, so I cannot try these tests. 1) Does it hang in syswrite(), we can check this by adding warn "HERE" after the syswrite on line 773 of LDAP.pm If it is in syswrite() maybe IO::Socket::SSL does not like data sent that size. We could try sending smaller chunks by changing the syswrite() line to be (warning - untested) my $to_send = \( $msg->pdu ); my $offset = 0; while($offset < length($$to_send)) { my $n = syswrite($socket, substr($$to_send, $offset, 15000), 15000) or return _error($ldap, $mesg, LDAP_LOCAL_ERROR,"$!"); $offset += $n; } Can someone who sees the problem please try this. Graham. On Jun 1, 2007, at 7:43 AM, Jozef Kutej wrote: > Hi Graham. > > I have the same problem as Swen. If I add attributes that have data > payload of 15949 bytes if works. But for 15994 it hangs. It hangs for > any size above it. Debug didn't told anything it just dumped the > packets and hanged waiting for ever. > > Jozef. > > On Fri, 2007-06-01 at 07:09 -0500, Graham Barr wrote: >> On May 30, 2007, at 11:38 AM, Swen Vermeul wrote: >>> >>> Somehow there seems to be a problem with the length of data being >>> transmitted. >>> We used the same code for years, without any problem, it stopped >>> working about two months ago. Maybe an update of Perl, a module or >>> OpenSSL is causing the trouble? >>> Does anybody have any clue how to track this bug? >> >> Can you tell the length of the packet being written that causes the >> hang ? >> >> You turn on debug with $ldap->debug(15); >> >> Graham. >> >