[Fedora-suds-list] setting a cookie
Mohamed Lrhazi
lrhazi at gmail.com
Wed Mar 18 01:43:59 UTC 2009
I am guessing here....
you are attempting to configure the http client to automatically
manage cookies for you...
if all you need is send a cookie and if you already know its value,
whats wrong with just setting it like I suggested as a simple
additional header?
are you over complicating it, or am completely mis understanding the issue?
Mohamed.
2009/3/17 David Bunch <david.e.bunch at gmail.com>:
> Is this not the correct way set a cookie in suds?
>
> # Create session cookie.
> oizysSessionCookie = cookielib.Cookie(version=None,
> name="ASP.NET_SessionId",
>
> value=self.loginCredentials.session_id,
> port="8082",
> port_specified=False,
> domain="127.0.0.1",
> domain_specified=True,
> domain_initial_dot=False,
> path="ISTSessionId",
> path_specified=True,
> secure=False,
> expires=None,
> discard=True,
> comment=None,
> comment_url=None,
> rest=None)
> # Add cookie to clients
> commandClient = Client(commandUrl)
>
> commandClient.options.transport.cookiejar.set_cookie(oizysSessionCookie)
> monitorClient = Client(monitorUrl)
>
> monitorClient.options.transport.cookiejar.set_cookie(oizysSessionCookie)
>
> _______________________________________________
> fedora-suds-list mailing list
> fedora-suds-list at redhat.com
> https://www.redhat.com/mailman/listinfo/fedora-suds-list
>
--
" Logic merely sanctions the conquests of the intuition."
Jacques Hadamard
More information about the fedora-suds-list
mailing list