September 28, 2004

Perl proxy server on Win32

Just a note: inspired by the HTTP::Recorder article and and my work on a web testing framework I was recently hunting around for a pure-Perl proxy server that runs on Win32. The problem is that the solution mentioned in the article, HTTP::Proxy, is based on <a href=”http://search.cpan.org/~gaas/libwww-perl-5.800/lib/HTTP/Daemon.pm</a>HTTP::Daemon</a>, and AFAICT it relies on fork() to do its work. (No, cygwin is not an option.)

So I searched some more on CPAN and found POE::Component::Proxy::TCP. Following the docs I setup a server really quickly and it worked perfectly. Sweet! Adding some code to generate the scenario descriptors was quick work after that.

It's not a general-purpose proxy server by any means (more of a tunnel), but it's useful to know.

Next: Administration: dress it up if it's good, restrict it if it's bad
Previous: New-ish blog: James Walcott