Advertisement
Guest User

Untitled

a guest
Jul 9th, 2017
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. <?php
  2.  
  3.  
  4.  
  5. $email = ' ';
  6.  
  7. $senha = ' ';
  8.  
  9.  
  10. $ch = curl_init();
  11.  
  12. curl_setopt($ch, CURLOPT_URL, 'https://host.com/login');
  13.  
  14. curl_setopt ($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6");
  15.  
  16. curl_setopt ($ch, CURLOPT_POST, 1);
  17.  
  18. curl_setopt ($ch, CURLOPT_POSTFIELDS, '_username=$email&_password=$senha');
  19.  
  20. curl_setopt($ch, CURLOPT_COOKIESESSION, true);
  21.  
  22. $store = curl_exec ($ch);
  23.  
  24. curl_setopt($ch, CURLOPT_URL, 'https://host.com/dashboard/');
  25.  
  26. curl_setopt ($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6");
  27.  
  28. $prok =curl_exec($ch);
  29.  
  30. curl_close ($ch);
  31.  
  32. echo $prok;
  33.  
  34.  
  35. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement