Hi all,

I have a nice running Soap-Server, which can be started in HTTP or HTTPS mode.

When I start this in HTTPS mode, and I telnet on the listening Port, the Server crashes, because of

"SSL connect accept failed because of handshake problemserror:00000000 +:lib(0):func(0):reason(0) ..."

How can i trap this, so that the server stays alive ?
Here's my code snippet:

if ($ssl) { $daemon = SOAP::Transport::HTTP::Daemon -> new (LocalPort => $port, Reuse => 1, SSL_use_cert => 1, SSL_key_file => 'path/to/server.key', SSL_cert_file => 'path/to/server.crt') -> on_action(sub {}) -> dispatch_to('allmy','methodes') ; } $daemon->handle;

When I try this:

eval{ $daemon->handle or warn($!); };

I got the errorcode, but nevertheless the server dies.

When I use HTTP (leave all the SSL tags in the above deamon out) , the Server sends a normal error message and stays alive

HTTP/1.1 400 Bad Request Date: Wed, 03 Nov 2010 10:59:54 GMT Server: libwww-perl-daemon/5.818 Content-Type: text/html Content-Length: 57 <title>400 Bad Request</title> <h1>400 Bad Request</h1>

Thanks in advance for any hint.

Regards Christian
-----------------------------------
--the good, the bad and the physi--
-----------------------------------

In reply to How to handle error in SOAP::Transport::HTTP::Daemon by physi

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.