[Twisted-Python] HTTP Gateway, Passing In Cookies Via URL

Brandon McGinty brandon.mcginty at gmail.com
Tue Nov 24 09:37:10 EST 2009


I hope someone can help me with this.
I have checked through the twisted web proxy and twisted http client, 
and I suppose I am just missing something.
I am trying to create a resource, inside a twisted web server, that will 
convert the arguments passed to it into an address, which is easy 
enough, and then act as a proxy between the actual client, and the 
server specified in the arguments. I would also like to set cookies 
based on the arguments.

An example might be useful:
client a accesses webserver b with something like:
get 
/cookieGateway?address=http%3A//www.google.com/search%3Fq%3Dtest&cookies=uid%3D123456%3B%20authToken%3Dabcdef
webserver b accesses address, and sends cookies specified in "cookies" 
parameter, and passess all headers from client a to address.
Each byte of data sent from "address" back to server b is returned 
immediately to client a, including response, headers, body, etc.

If anyone can give me a hand with this, I would greatly appreciate it.
I hope I have been clear enough.

Sincerely,
Brandon McGinty





More information about the Twisted-Python mailing list