Advertisement
Guest User

Untitled

a guest
Sep 15th, 2019
271
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.71 KB | None | 0 0
  1. <?php
  2. //Auto Regis CinePoint With US Number
  3. //Created By Alip Dzikri
  4.  
  5. // Headers
  6. $headers = array();
  7. $headers[] = 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6ImNpbmVwb2ludCIsInBhc3N3b3JkIjoiJSVjaW5lcG9pbnQlJSIsImlhdCI6MTU2ODUyNjg5NywiZXhwIjoxNjY4NTI2Nzk3LCJzdWIiOiJjaW5lcG9pbnQuY29tIn0.1YYyV4PgosN5zJUjDkwAH0wbgqHiTq2Jiu1SPklCB-I';
  8. $headers[] = 'Content-Type: application/json';
  9. $headers[] = 'Connection: Keep-Alive';
  10. $headers[] = 'User-Agent: okhttp/3.12.1';
  11. //
  12. $test = file_get_contents('https://api.randomuser.me');
  13. preg_match('/"first":"(.*?)",/',$test,$first);
  14. echo "====================================== \n";
  15. echo "Auto regis Cinepoint with US Number \n";
  16. echo "Created By alip dzikri \n";
  17. echo "====================================== \n";
  18. echo " Refferall : ";
  19. $reff = trim(fgets(STDIN));
  20. echo "Nomor US : Ex(928xxxxx) ";
  21. $nomor = trim(fgets(STDIN));
  22.  
  23. $bodyceknope = '{"country_id": "Wpmbk5XezJ","mobile_number": "'.$nomor.'"}';
  24. $ceknope = curl('https://api.cinepoint.id/user/check-mobile-number',$bodyceknope,$headers);
  25.  
  26. $jsceknope = json_decode($ceknope[0]);
  27. if($jsceknope->data->detail->exist == 1 ){
  28. print_r($jsceknope);
  29. die("Nomor Udah Di Pake /n");
  30. } else {
  31. $getotp = curl('https://api.cinepoint.id/otp/request',$bodyceknope,$headers);
  32. $jsgetotp = json_decode($getotp[0]);
  33. if($jsgetotp->meta->message == "OTP sent."){
  34. echo "OTP : ";
  35. $otp = trim(fgets(STDIN));
  36. $verifotp = curl('https://api.cinepoint.id/otp/verify','{"country_id": "Wpmbk5XezJ","mobile_number": "'.$nomor.'","otp": "'.$otp.'"}',$headers);
  37. $jsverifotp = json_decode($verifotp[0]);
  38. if($jsverifotp->data->detail->success == 1){
  39.  
  40. echo "Status : ";
  41. $pesan = $jsverifotp->data->detail->success;
  42. echo $pesan;
  43. echo "\n";
  44. $token = $jsverifotp->data->detail->token;
  45. echo $token;
  46. $bodyregister = '{ "country_id": "Wpmbk5XezJ", "debug": false, "device_id": "a56e2aed079e8bac", "first_name": "'.$first[1].'", "gender": "female", "last_name": "alif", "mobile_number": "'.$nomor.'", "referral_id": "'.$reff.'", "token": "'.$token.'", "username": "'.$first[1].'al'.rand(100,999).'"}';
  47. $register = curl('https://api.cinepoint.id/user', $bodyregister, $headers);
  48. $jsregister = json_decode($register[0]);
  49. if($jsregister->data->detail->status == "active"){
  50. echo "SUKSES REGIS DENGAN REFF ".$reff." \n";
  51. } else {
  52. echo "Gagal \n";
  53. }
  54. } else {
  55. print_r($jsverifotp);
  56. }
  57. } else {
  58. print_r($jsgetotp);
  59. }
  60. }
  61.  
  62.  
  63.  
  64.  
  65.  
  66. function nama()
  67. {
  68. $ch = curl_init();
  69. curl_setopt($ch, CURLOPT_URL, "http://ninjaname.horseridersupply.com/indonesian_name.php");
  70. curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
  71. curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
  72. curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  73. curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
  74. $ex = curl_exec($ch);
  75. // $rand = json_decode($rnd_get, true);
  76. preg_match_all('(&bull; (.*?)<br/>&bull; )', $ex, $name);
  77. return $name[2][mt_rand(0, 14) ];
  78. }
  79.  
  80. function curl($url, $fields = null, $headers = null)
  81. {
  82. $ch = curl_init();
  83. curl_setopt($ch, CURLOPT_URL, $url);
  84. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  85. curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
  86. curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
  87. if ($fields !== null) {
  88. curl_setopt($ch, CURLOPT_POST, 1);
  89. curl_setopt($ch, CURLOPT_POSTFIELDS, $fields);
  90. }
  91. if ($headers !== null) {
  92. curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
  93. }
  94. $result = curl_exec($ch);
  95. $httpcode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
  96. curl_close($ch);
  97.  
  98. return array(
  99. $result,
  100. $httpcode
  101. );
  102. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement