Loading ...
Sorry, an error occurred while loading the content.

5017SOAP::Transport::TCP and SSL

Expand Messages
  • Joe
    Nov 18, 2005
    • 0 Attachment
      Hi Everyone,

      I'm trying to get a Soap server running using SOAP::Transport::TCP
      with an SSL connection. From everything I've read, I should be able
      to add an SSL option into the new call and it will establish an SSL
      socket. Unfortunately, I'm getting a no such file or directory error
      when I try to run with the SSL option. Without the SSL option
      everything works fine.

      I know I could use Apache + ssl to establish the ssl connection, but I
      would like to try to do this without apache on a fairly small system
      which already has perl.

      Any ideas?


      Server Code:
      use SOAP::Transport::TCP;

      $daemon = SOAP::Transport::TCP::Server
      -> new (LocalPort => 8080,
      Listen => 5,
      Reuse => 1,
      SSL_server => 1)
      -> dispatch_to('/home/rockljo/SOAP/modules')

      print "Contact to SOAP server at ",
      $daemon->sockhost, ":", $daemon->sockport, "\n";

      #> ./server.pl
      Can't open socket: No such file or directory at ./server.pl line 5

      Client Code:
      #!/usr/bin/perl -w

      use SOAP::Lite +trace;

      $req = SOAP::Lite
      -> uri('/Demo')
      -> proxy('tcp://')
      -> hi;

      print "Response from server is: " . $req->result() . "\n";

      Demo.pm is set up - as I mentioned above, without the SSL option
      everything works as intended.