[Twisted-Python] http proxy
andreww at datanet.ab.ca
Mon Feb 25 03:08:26 EST 2008
Vasil Vangelovski wrote:
>I'm trying to set up a http proxy which will write redirects to the
>client if it requests certain uri but work as a normal proxy for
>others. Can this be done with the higher level proxy classes, if so,
Not easily. The proxy classes included with Twisted only really work for
a simple transparent non-authenticating proxy. Also, twisted.web2.proxy
was incomplete and didn't work the last time I checked.
twisted.web.proxy works, but is only compatible with HTTP/1.0 and does
not allow persistent connections or pipelining.
I am in the process of writing a Twisted-based proxy that supports
filter plugins (the site is http://xuproxy.sourceforge.net). Currently,
it is in an alpha state (transparent HTTP proxying with pipelining
support appears to be fully working, but there may be major bugs
lurking), so I wouldn't recommend using it for production use.
More information about the Twisted-Python