$req = HTTP::Request->new("CONNECT", "http://proxy1_host:proxy1_port/proxy2_host:proxy2_port", HTTP::Headers->new(), "GET http://final_destination.example.com/ HTTP/1.0\cJ\cM\cJ\cM");