Danett song wrote:
> The program work perfectly when i'm requesting only
> HTTP pages with multiple threads, however when I
> change HTTP to HTTPS with multiple threads the program
> crash (segmentation fault / access violation). If I
> use HTTPS and only one thread the program work
> perfectly.
>
> That's looks like really strange for me, which come to
> my mind is that HTTPS is not thread safe in perl?
It has nothing to do with the protocol per se, but with the
modules that implement it.
> I have SSL modules instaled...
>
> libcrypt-ssleay-perl 0.51-5
> libio-socket-ssl-perl 1.01-1
> libnet-ssleay-perl 1.30-1
Jerry D. Hedden wrote:
> Most likely, one or more of these modules is not
> thread-safe. You need to file bug reports against
whichever
> of these you can determine is the problem (or all if
you can
> not).
>
> If you read the POD for the 'threads' module, it
discusses
> possible work arounds for non-thread-safe modules.
>
> This is not a bug with the Perl interpreter. As such,
this
> bug report should be closed.
Tels wrote:
> Not so fast. I remember there was a bug in blead fixed
very recently
> that showed that if you grabbed enough things with LWP
fast enough (or
> loaded enough modules fast enough?), it would go
*boom*. Sorry, but I
> can't remeber which bug that was.
However, the originator reported that the threaded app
works
perfectly with HTTP (i.e., without the suspect modules),
but
fails with HTTPS (i.e., with the suspect modules).
Net::SSLeay and Crypt::SSLeay are both XS modules which are
notorious for not being thread-safe. Additionally, the POD
for Net::SSLeay has caveats related to thread usage.
|