Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Proxy server with Authentication

by abhishes (Friar)
on Feb 20, 2003 at 15:24 UTC ( #237111=perlquestion: print w/replies, xml ) Need Help??

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 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.


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

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, should get you started down the right path

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://237111]
Approved by pfaut
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (5)
As of 2019-11-17 12:25 GMT
Find Nodes?
    Voting Booth?
    Strict and warnings: which comes first?

    Results (86 votes). Check out past polls.