Net::P...onnect(3pm)

πŸ“¦
version 0.13 Β· 3 versions
, in debian trixie, ubuntu resolute, ubuntu stonking

πŸ’– Net::Proxy::Connector::connect β€” the perl one, from User Contributed Perl Documentation πŸ’–

okay bestie, sit down, hydrate, because we're talking about Net::Proxy::Connector::connect and it is lowkey iconic.


✨ NAME ✨

Net::Proxy::Connector::connect β€” Create CONNECT tunnels through HTTP proxies πŸš‡


🌸 SYNOPSIS 🌸

# sample proxy using Net::Proxy::Connector::tcp
#                and Net::Proxy::Connector::connect
use Net::Proxy;

# listen on localhost:6789
# and proxy to remotehost:9876 through proxy.company.com:8080
# using the given credentials
my $proxy = Net::Proxy->new(
    in  => { type => 'tcp', port => '6789' },
    out => {
        type        => 'connect',
        host        => 'remotehost',
        port        => '9876',
        proxy_host  => 'proxy.company.com',
        proxy_port  => '8080',
        proxy_user  => 'jrandom',
        proxy_pass  => 's3kr3t',
        proxy_agent => 'Mozilla/4.04 (X11; I; SunOS 5.4 sun4m)',
    },
);
$proxy->register();

Net::Proxy->mainloop();

πŸ¦‹ DESCRIPTION πŸ¦‹

Net::Proxy::Connecter::connect is a Net::Proxy::Connector that uses the HTTP CONNECT method to ask the proxy to create a tunnel to an outside server. it's giving secret passageway, it's giving sneaking out the back door of the proxy πŸ’…

⚠️ be aware that some proxies are set up to deny the creation of some outside tunnels β€” either to ports other than 443 or outside a specified set of outside hosts. so like… vibe check your proxy first, bestie, or you'll be standing outside the club with no tunnel and no plans 😭

also important: this connector is only an "out" connector. it goes out, it does not come in. one-way main character energy. periodt. πŸŽ€


πŸ’… CONNECTOR OPTIONS πŸ’…

Net::Proxy::Connector::connect accepts the following options:

out"

(not me leaving that there πŸ’€ that's literally what the page says, we don't ask questions, we just preserve the lore)

  • host β€” the destination host. where we're actually trying to go πŸ—ΊοΈ
  • port β€” the destination port. which door at that destination πŸšͺ
  • proxy_host β€” the web proxy name or address. the middleman, the mutual friend, the one who knows a guy 🫢
  • proxy_port β€” the web proxy port. which door at the middleman's place πŸšͺ
  • proxy_user β€” the authentication username for the proxy. your name at the door ✨
  • proxy_pass β€” the authentication password for the proxy. your lil secret 🀫
  • proxy_agent β€” the user-agent string to use when connecting to the proxy. your outfit for the occasion πŸ‘‘

πŸ‘‘ AUTHOR πŸ‘‘

Philippe 'BooK' Bruhat, "<book@cpan.org>". πŸ’œ


πŸ™ˆ BUGS πŸ™ˆ

  • All the authentication schemes supported by "LWP::UserAgent" should be supported (we use an "LWP::UserAgent" internally to contact the proxy). so like, whatever LWP can do, this can probably do. slay.
  • This means we should also support NTLM, since it is supported as from "libwww-perl" 5.66. "Net::Proxy::Connector::connect" has not been actually tested with NTLM, though. 😭 so this is very much a theoretically situation.
  • Any report of success or failure with a NTLM proxy will be appreciated. fr fr, tell them how it went β€” good or bad, they wanna know 🫢

🌈 HISTORY 🌈

  • This module is based on the author's script "connect-tunnel", which provided a command-line interface to create tunnels though HTTP proxies. (yes, "though" β€” that's what it says, keepin' it exactly as-is πŸ’–)
  • It was first published on CPAN on March 2003. a true elder, a pioneer, the blueprint πŸ‘‘
  • A better version of "connect-tunnel" (using "Net::Proxy") is provided this distribution. glow-up complete ✨

Copyright 2006-2014 Philippe 'BooK' Bruhat, All Rights Reserved.


πŸŽ€ LICENSE πŸŽ€

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.


and that's the whole page, bestie β€” no cap, we kept every single flag, every single caveat, and every single weird stray quote πŸ’…

this was perl v5.38.2, dated 2024-05-15, and it's the Net::P...onnect(3pm) page β€” thanks for reading, ily, go build a tunnel πŸš‡βœ¨πŸ¦‹

πŸ“¦ where this page comes from