abhishes has asked for the wisdom of the Perl Monks concerning the following question:

Hello Perl Monks,

I am trying to use perl to connect to a url and download a web page. I am connected to the internet using a proxy server. moreover, the proxy server needs authentication..so I need to pass user id and password.

I checked out Net::HTTP package documentation but it did not contain anything on proxy configuration. Please give me some links which show how can this be done. I was tempted to use Win32::Internet module because there the proxy documentation is there but then my script will not be portable.

regards,
Abhishek

Replies are listed 'Best First'.
Re: (nrd) Proxy server with Authentication
by newrisedesigns (Curate) on Feb 20, 2003 at 17:07 UTC

    If you're using LWP, try calling the env_proxy() function however, I can't find anywhere where you could send a username and password along with it.

    John J Reiser
    newrisedesigns.com

Re: Proxy server with Authentication
by phydeauxarff (Priest) on Feb 20, 2003 at 20:43 UTC
    At the risk of sounding repetative, since I previously recommended much (OK....exactly <grin>) the same solution to 2mths in node 235034 .....
    take a look at the CPAN module, Net::HTTPTunnel...it should get you started down the right path