Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/perl
- #1-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=0
- #0 _ __ __ __ 1
- #1 /' \ __ /'__`\ /\ \__ /'__`\ 0
- #0 /\_, \ ___ /\_\/\_\ \ \ ___\ \ ,_\/\ \/\ \ _ ___ 1
- #1 \/_/\ \ /' _ `\ \/\ \/_/_\_<_ /'___\ \ \/\ \ \ \ \/\`'__\ 0
- #0 \ \ \/\ \/\ \ \ \ \/\ \ \ \/\ \__/\ \ \_\ \ \_\ \ \ \/ 1
- #1 \ \_\ \_\ \_\_\ \ \ \____/\ \____\\ \__\\ \____/\ \_\ 0
- #0 \/_/\/_/\/_/\ \_\ \/___/ \/____/ \/__/ \/___/ \/_/ 1
- #1 \ \____/ >> Exploit database separated by exploit 0
- #0 \/___/ type (local, remote, DoS, etc.) 1
- #1 1
- #0 [+] Site : 1337day.com 0
- #1 [+] Support e-mail : submit[at]1337day.com 1
- #0 0
- #1 ######################################### 1
- #0 I'm The Black Devils member from Inj3ct0r Team 1
- #1 ######################################### 0
- #0-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-==-=-=-1
- # To ExCUTE IT
- # PERL FILE.PL 192.168.1.1 1 65000
- use warnings;
- use strict;
- use IO::Socket;
- system("title The Black Devils");
- system("color 1e");
- system("cls");
- print "\n\n";
- print " |=======================================================|\n";
- print " |= [!] Name : The Black Devils Port Scanner V 1.0 || =|\n";
- print " |= [!] Author : The Black Devils =|\n";
- print " |= [!] Mail: mr.k4rizma(at)gmail(dot)com =|\n";
- print " |= Perl Dz.pl target port1 port 2 =|\n";
- print " |=======================================================|\n";
- sleep(2);
- print "\n";
- # Creating ...
- # User Var
- my $iptarget = $ARGV[0] ;
- my $x = $ARGV[1];
- my $y = $ARGV[2];
- unless($ARGV[0]){print "|MISSING IP ADRESS\n\n";exit;}
- print "Interesting ports on $iptarget\n\n";
- print "PORT // STATE // SERVICE\n";
- scan($iptarget);
- print "Scan Finish\n";
- exit;
- # Scanning fonction
- sub scan
- {
- my ($inputtarget) = @_;
- for( my $iport = $x; $iport != $y; $iport++)
- {
- if ( my $remote = IO::Socket::INET->new(
- Proto => "tcp",
- PeerAddr => $inputtarget,
- PeerPort => $iport,
- Timeout => "5"
- )){
- (my $name, my $aliases, my $port_number, my $protocol_name) =
- +getservbyport( $iport , "tcp" );
- if($name){ $name = $name;}else{$name = "NA";}
- print "$iport";print" open";print" $name\n";
- close($remote);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement