Jump to content
kw3rln

[Perl] Link clicker

Recommended Posts

Posted
require LWP::UserAgent;
$proxyfile = $ARGV[1];
$url = $ARGV[0];
if(!$proxyfile || !$url)
{
print "USAGE: script.pl [url]http://www.site.com[/url] proxy_file.txt";
exit;
}

@useragents = ('Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1','Mozilla/4.0 (compatible; MSIE is not me; DAUMOA/1.0.1; DAUM Web Robot; Daum Communications Corp., Korea) ','Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.0.9) Geck','Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; (R1 1','Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 1','Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)','Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1) Gecko/','Mozilla/5.0 (Windows; U; Windows NT 5.0; nl; rv:1.8.0.9) Geck','Mozilla/4.0 (compatible; MSIE 5.0; Mac_PowerPC)','Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2','Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)','Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.0.8) Geck');
open(PROXY,$proxyfile);
@proxies = <PROXY>;
print "\n[] Script by Iron ([url]http://www.ironwarez.info[/url])";
print "\n[]Database (".$proxyfile.") contains ".scalar(@proxies)." proxies.";

$succes = 0;
$failed = 0;
foreach $proxy(@proxies)
{
chomp($proxy);

my $ua = LWP::UserAgent->new;

$ua->timeout(30);
$ua->env_proxy;
$ua->agent(@data[int(rand(scalar(@data)))]);
$ua->proxy('http', 'http://'.$proxy);

my $response = $ua->get($url);

if ($response->is_success) {
print "\n[+]".$proxy." -> succes";
$succes++;
}
else
{
print "\n[-]".$proxy." -> failed";
$failed++;
}
}
print "\n[Total] Succesful connections: ". $succes."\nFailed connections: ".$failed;

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...