#!/usr/bin/perl use HTTP::Proxy; use HTTP::Recorder; my $proxy = HTTP::Proxy->new( port => 3128 ); my $agent = new HTTP::Recorder; $agent->file("/tmp/myfile"); $proxy->agent( $agent ); $proxy->start(); 1;