Simple localhost/proxy Server
nick at nick8325.freeserve.co.uk
Fri Jul 23 16:57:45 CEST 2004
"Fuzzyman" <michael at foord.net> wrote in message
news:8089854e.0407230627.525eba34 at posting.google.com...
> I am trying to write a small server program that will work on a
> *client* machine as a localhost server. It should then act as a proxy
> server but modify URLs fetched through it - so that the fetches go via
> an external CGI proxy.... Understand all that ? :-)
> (I have a working CGI proxy that will remotely fetch web pages that I
> can't access. The CGI proxy knows which page to fetch through the
> PATH_INFO environment variable. What I'd like to do is write a little
> server program that will sit on the client machine and modify URL
> requests so that they go *via* the CGI proxy..).
> So I have a few examples of proxy server programs - like tcpwatch and
> the Tiny HTTP Debugging proxy - but I'm afraid my knowledge of http is
> so little that I'm struggling to feel my way through. (Although I've
> written a few CGIs..).
> Can anyone point me in the right direction ?
> A localhost server that I can get a response from with my browser -
> and can see the requests coming in python - would be cool.
> I run 'Tiny HTTP Proxy' by SUZUKI Hisao and it prints :
> Any clients will be served...
> Serving HTTP on 0.0.0.0 port 8000 ...
> But can I get it to respond... can I jigger..........
> I put 0.0.0.0 port 8000 as my proxy settings in IE, I
> http://0.0.0.0:8000 or just plain 0.0.0.0 in the address bar...
> nothing seems to make it respond...
> Hmmm... out of my depth I'm afraid.
You won't get much luck trying to send packets to 0.0.0.0. Perhaps if you
try 127.0.0.1 port 8000 as your proxy.
More information about the Python-list