You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by David Q Levitt <dq...@us.ibm.com> on 2002/11/19 18:04:59 UTC

servlet Cookie vs SOAP Cookie




In my portlet I've obtained the LtpaToken cookie, which is an instance of
javax.servlet.http.Cookie.  For the purpose of Single Sign On, I want to
pass this cookie to a web service via the SOAP request.

 I downloaded the latest SOAP jar which contains a Call.invoke() method
that accepts a Hashtable argument.  I tried putting my LtpaToken cookie
into the Hashtable but when I execute the Call.invoke() method I'm getting
a ClassCastException on javax.servlet.httpCookie.  My guess is that SOAP
doesn't recognize the servlet cookie.

Next I was going to try using the SOAPHTTPConnection.setCookies() method
but I run into the same problem - that method only accepts SOAP cookies,
not servlet cookies.

Is there any workaround for this cookie incompatibilty problem?



Re: servlet Cookie vs SOAP Cookie

Posted by Scott Nichol <sn...@scottnichol.com>.
You could try

Hashtable headers = new Hashtable();
headers.add("Cookie", ssoCookie.getName() + "=" + ssoCookie.getValue());
...
call.invoke(.., .., headers);

Scott Nichol

----- Original Message -----
From: "David Q Levitt" <dq...@us.ibm.com>
To: <so...@xml.apache.org>
Sent: Tuesday, November 19, 2002 12:04 PM
Subject: servlet Cookie vs SOAP Cookie


>
>
>
>
> In my portlet I've obtained the LtpaToken cookie, which is an instance
of
> javax.servlet.http.Cookie.  For the purpose of Single Sign On, I want
to
> pass this cookie to a web service via the SOAP request.
>
>  I downloaded the latest SOAP jar which contains a Call.invoke()
method
> that accepts a Hashtable argument.  I tried putting my LtpaToken
cookie
> into the Hashtable but when I execute the Call.invoke() method I'm
getting
> a ClassCastException on javax.servlet.httpCookie.  My guess is that
SOAP
> doesn't recognize the servlet cookie.
>
> Next I was going to try using the SOAPHTTPConnection.setCookies()
method
> but I run into the same problem - that method only accepts SOAP
cookies,
> not servlet cookies.
>
> Is there any workaround for this cookie incompatibilty problem?
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@xml.apache.org>
> For additional commands, e-mail:
<ma...@xml.apache.org>
>
>


Re: servlet Cookie vs SOAP Cookie

Posted by Scott Nichol <sn...@scottnichol.com>.
You could try

Hashtable headers = new Hashtable();
headers.add("Cookie", ssoCookie.getName() + "=" + ssoCookie.getValue());
...
call.invoke(.., .., headers);

Scott Nichol

----- Original Message -----
From: "David Q Levitt" <dq...@us.ibm.com>
To: <so...@xml.apache.org>
Sent: Tuesday, November 19, 2002 12:04 PM
Subject: servlet Cookie vs SOAP Cookie


>
>
>
>
> In my portlet I've obtained the LtpaToken cookie, which is an instance
of
> javax.servlet.http.Cookie.  For the purpose of Single Sign On, I want
to
> pass this cookie to a web service via the SOAP request.
>
>  I downloaded the latest SOAP jar which contains a Call.invoke()
method
> that accepts a Hashtable argument.  I tried putting my LtpaToken
cookie
> into the Hashtable but when I execute the Call.invoke() method I'm
getting
> a ClassCastException on javax.servlet.httpCookie.  My guess is that
SOAP
> doesn't recognize the servlet cookie.
>
> Next I was going to try using the SOAPHTTPConnection.setCookies()
method
> but I run into the same problem - that method only accepts SOAP
cookies,
> not servlet cookies.
>
> Is there any workaround for this cookie incompatibilty problem?
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@xml.apache.org>
> For additional commands, e-mail:
<ma...@xml.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@xml.apache.org>
For additional commands, e-mail: <ma...@xml.apache.org>