Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Connecting through a proxy server (without LWP)

by batkins (Chaplain)
on Oct 08, 2003 at 18:41 UTC ( [id://297689]=perlquestion: print w/replies, xml ) Need Help??

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

I have a Perl script that needs to connect to a server on port 80. Unfortunately, the network I have to run this on requires usage of an NTLM proxy for all outgoing connections. I'm using port 80 because as far as I can tell, all other ports have been blocked, and the server to which I'm connecting accepts connections on all ports.

I had trouble getting Authen::NTLM to work, so I downloaded NTLMAPS from SourceForge, gave it my credentials, and pointed it at my proxy. I tried setting my proxy to localhost in Opera and it successfully tunneled pages (Opera never worked before because it doesn't understand NTLM).

But the problem is that I'm not sure how to go about getting through the local proxy set up by NTLMAPS. I can't use LWP for this (I'm not retrieving Web data). So how do I tunnel a regular Perl socket through an anonymous proxy?

Any help would be appreciated.

TIA,
Bill

  • Comment on Connecting through a proxy server (without LWP)

Replies are listed 'Best First'.
Re: Connecting through a proxy server (without LWP)
by hardburn (Abbot) on Oct 08, 2003 at 20:07 UTC

    Anonymous proxies are, well, anonymous. They transparently grab connections without programs being aware of it.

    That said, look at IO::Socket::Socks and Net::HTTPTunnel.

    ----
    I wanted to explore how Perl's closures can be manipulated, and ended up creating an object system by accident.
    -- Schemer

    Note: All code is untested, unless otherwise stated

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://297689]
Approved by bassplayer
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (None)
    As of 2024-04-19 00:12 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      No recent polls found