Advertisement
Guest User

auth.php

a guest
Apr 28th, 2015
437
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.15 KB | None | 0 0
  1. <?
  2.  
  3. $login = htmlspecialchars(stripslashes(addslashes($_POST['log'])));
  4. $pass = htmlspecialchars(stripslashes(addslashes($_POST['pas'])));
  5.  
  6. setcookie('hatalog', $login, time()+86400);
  7. setcookie('hatapass', $pass, time()+86400);
  8. echo'<div class="menu"><center>';
  9. define('PROTECTOR', 1);
  10.  
  11.  
  12. $textl='Герой-Спамер';
  13. include('files/path.php');
  14. include($path.'files/head.php');
  15.  
  16.  
  17.  
  18. $login = htmlspecialchars(stripslashes(addslashes($_POST['log'])));
  19. $pass = htmlspecialchars(stripslashes(addslashes($_POST['pas'])));
  20. $url = 'http://passport.vmmo.ru/login.html?';
  21. $u="http://hata.mobi/index.php?r=site/login";
  22. $uu="http://passport.vmmo.ru/j_spring_security_check";
  23. $post =
  24. 'action=_spring_security_remember_me='."true".
  25. '&j_username=' . $login .
  26. '&j_password=' . $pass .
  27. '&openid.return_to=' . $u .
  28. '&submit=' . "submit";
  29.  
  30.  
  31. $ch = curl_init();
  32. curl_setopt($ch, CURLOPT_URL, $uu) ;
  33. //curl_setopt ($ch, CURLOPT_HEADER, true);
  34. curl_setopt ($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 6.1) ");
  35. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  36. curl_setopt($ch, CURLOPT_COOKIEJAR, "cookie/$login.txt");
  37. curl_setopt($ch, CURLOPT_COOKIEFILE, "cookie/$login.txt");
  38. curl_setopt($ch, CURLOPT_HEADER, false);
  39. curl_setopt($ch, CURLOPT_TIMEOUT, 10);
  40. curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
  41. curl_setopt($ch, CURLOPT_POSTFIELDS, $post);
  42. $html = curl_exec($ch);
  43. curl_close($ch);
  44. $poss = StrPos($html,"Пароль");
  45. if ( $poss === false ){
  46.  
  47. echo "<h1><center>Все ОК братишка <img src='http://spaces.ru/i/ment.gif'><img src='http://spaces.ru/i/boss.gif'> </center></h1>";
  48.  
  49.  
  50. echo"<meta http-equiv='refresh' content='1; url=config.php' >";
  51. }else{
  52. echo "<h1><center><font color='black'>Неполадки старичек</font><img src='http://spaces.ru/i/nea.gif'></center></h1>";
  53. echo"<meta http-equiv='refresh' content='3; url=log.php' >";
  54. echo'<a class="button" href="log.php"><font size="2">Назад</font></a><br><br></div>';
  55. unlink("cookie/$login.txt");
  56. //echo $html ;
  57. }
  58. echo'</center>';
  59. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement