#!/usr/bin/perl use strict; use warnings; use HTTP::Proxy; use HTTP::Recorder; my $proxy = HTTP::Proxy->new( port => 3333 ); # create a new HTTP::Recorder object my $agent = new HTTP::Recorder; # set the log file $agent->file("c:/htr1.txt"); # set HTTP::Recorder as the agent for the proxy $proxy->agent($agent); #start the proxy $proxy->start(); 1;