POE::Component::Proxy::SOCKS

A POE based SOCKS 4 proxy server
Download

POE::Component::Proxy::SOCKS Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Chris Williams
  • Publisher web site:
  • http://search.cpan.org/~bingos/

POE::Component::Proxy::SOCKS Tags


POE::Component::Proxy::SOCKS Description

A POE based SOCKS 4 proxy server POE::Component::Proxy::SOCKS is a Perl module that implements a SOCKS version 4/4a proxy server. It has IP address based access controls, provided by Net::Netmask, and can use IDENT to further confirm user identity.POE sessions may register with the SOCKS component to receive events relating to connections etc.The poco supports both SOCKS CONNECT and SOCKS BIND commands.SYNOPSIS use strict; use Net::Netmask; use POE qw(Component::Proxy::SOCKS); $|=1; POE::Session->create( package_states => , ], ); $poe_kernel->run(); exit 0; sub _start { my ($kernel,$heap) = @_; $heap->{socksd} = POE::Component::Proxy::SOCKS->spawn( alias => 'socksd', ident => 0 ); return; } sub socksd_registered { my $socksd = $_; my $all = Net::Netmask->new2('any'); my $loopback = Net::Netmask->new2('127.0.0.1'); my $local = Net::Netmask->new2('192.168.1.0/24'); $socksd->add_denial( $all ); $socksd->add_exemption( $loopback ); $socksd->add_exemption( $local ); return; } sub _default { my ($event, $args) = @_; my @output = ( "$event: " ); foreach my $arg ( @$args ) { if ( ref($arg) eq 'ARRAY' ) { push( @output, "" ); } else { push ( @output, "'$arg'" ); } } print STDOUT join ' ', @output, "\n"; return 0; } Requirements: · Perl


POE::Component::Proxy::SOCKS Related Software