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

storing cookies + wsdl

Expand Messages
  • ktrott1 <ktrott@orga.com>
    i have a WEB Service running (GLUE Server) with WSDL, which returns a cookie after calling a login service, which shall be used in subsequent calls to the
    Message 1 of 1 , Feb 13, 2003
      i have a WEB Service running (GLUE Server) with WSDL, which returns
      a cookie after calling a login service, which shall be used in
      subsequent calls to the server.
      I need some advice on how to save and reuse this cookie in
      subsequent calls ?
      <!--- code starts here ---------
      #!/usr/bin/perl -w

      #use SOAP::Lite;
      use SOAP::Lite +trace =>all;
      use HTTP::Cookies;

      my ($user,$pw ) = (@ARGV);

      my $cookie_file = './cookie';
      my $cookie_jar = HTTP::Cookies->new(ignore_discard => 1 );

      my $useraccess = SOAP::Lite
      -> proxy('http://localhost/', cookie_jar => $cookie_jar)
      ->
      service('http://od-solaris-5.orga.com:8123/gsmr/urn:userAccess.wsdl',);

      my $resp1 = $useraccess->login($user,$pw);

      print "Response for $user login:\n $resp1\n";

      my $profileadmin = SOAP::Lite
      -> proxy('http://localhost/', cookie_jar => $cookie_jar)
      ->
      service('http://od-solaris-5.orga.com:8123/gsmr/urn:profileAdmin.wsdl',);

      my $resp3 = $profileadmin->findTechnicalProfiles("T*");

      print "Response for findTechnicalProfiles:\n $resp3\n";
    Your message has been successfully submitted and would be delivered to recipients shortly.