exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

portcheck.pl.txt

portcheck.pl.txt
Posted Aug 31, 2005
Site rst.void.ru

Simple and efficient port scanning utility to audit what ports are open on a machine. Works much like netstat without having to trust netstat.

systems | unix
SHA-256 | d82b6fbf527183bbc75ad70635488c19834d003b841acb9c88a06612ff13c43f

portcheck.pl.txt

Change Mirror Download
#!/usr/bin/perl
use strict;use IO::Socket;my$port1=$ARGV[0];my$port2=$ARGV[1];my$proto=$ARGV[2];my$t="tcp";my$u="udp";my$wanted="0";my$deadline="1024";my$port;
sub header{print qq~
Test *REAL OPEN* ports
UDP or TCP protocols
for incoming and outgoing connections
Netstat & rootkits goto hell
Usage: $0 [port from] [port to] [proto]
Tested on FreeBSD, OpenBSD and Linux\n\n~;}
sub header2{print qq~
Force & fast check ports
Idea and C code author is rash
http://anarchy.blackhat.ru
Gr33tz: blf, 1dt.w0lf, edisan
(c)oded x97Rang, RST/GHC 2005
http://rst.void.ru
http://ghc.ru\n\n~;}
sub usage{&header;exit;}sub check{&header2;if($>ne$wanted){if($port1<$deadline){print"You are not root, and ports < 1024 not yours :)\n";exit;}}
if($port2>65535||$port1>$port2||$port1<1){print"Error in arguments, check range ports\n";exit}
if($proto eq $t){print"Let's begin:\n";print"Ports for $proto\n";print"From $port1 to $port2\n";print"Wait...\n";for($port=$port1;$port!=$port2;$port++){my$serv=IO::Socket::INET->new(Proto=>"$proto",LocalPort=>"$port",Type=>SOCK_STREAM,Reuse=>1,Listen=>10)or print" $port OPEN\n";}}
elsif($proto eq $u){print"Let's begin:\n";print"Ports for $proto\n";print"From $port1 to $port2\n";print"Wait...\n";for($port = $port1;$port!=$port2;$port++){my$serv=IO::Socket::INET->new(Proto=>"$proto",LocalPort=>"$port")or print" $port OPEN\n";}}else{print"Check for tcp or udp protocols ONLY!\n";exit}}if(@ARGV!=3){&usage;}else{&check;print"Done.\n";}










Login or Register to add favorites

File Archive:

August 2022

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Aug 1st
    20 Files
  • 2
    Aug 2nd
    4 Files
  • 3
    Aug 3rd
    6 Files
  • 4
    Aug 4th
    55 Files
  • 5
    Aug 5th
    16 Files
  • 6
    Aug 6th
    0 Files
  • 7
    Aug 7th
    0 Files
  • 8
    Aug 8th
    13 Files
  • 9
    Aug 9th
    13 Files
  • 10
    Aug 10th
    34 Files
  • 11
    Aug 11th
    16 Files
  • 12
    Aug 12th
    5 Files
  • 13
    Aug 13th
    0 Files
  • 14
    Aug 14th
    0 Files
  • 15
    Aug 15th
    25 Files
  • 16
    Aug 16th
    3 Files
  • 17
    Aug 17th
    6 Files
  • 18
    Aug 18th
    0 Files
  • 19
    Aug 19th
    0 Files
  • 20
    Aug 20th
    0 Files
  • 21
    Aug 21st
    0 Files
  • 22
    Aug 22nd
    0 Files
  • 23
    Aug 23rd
    0 Files
  • 24
    Aug 24th
    0 Files
  • 25
    Aug 25th
    0 Files
  • 26
    Aug 26th
    0 Files
  • 27
    Aug 27th
    0 Files
  • 28
    Aug 28th
    0 Files
  • 29
    Aug 29th
    0 Files
  • 30
    Aug 30th
    0 Files
  • 31
    Aug 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Hosting By
Rokasec
close