krischan039
Addict
- Joined
- Aug 6, 2017
- Posts
- 33
- Reaction
- 9
- Points
- 69
Here's my code
define('UserName', 'sample@gmail.com');
define('Password', 'samplesample');
define('_RequestVerificationToken',"'');
define('KeepMeLoggedIn','TRUE');
define('USER_AGENT', 'Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.2309.372 Safari/537.36');
define('cøøkíé_FILE', 'account.txt');
define('LOGIN_FORM_URL', 'You do not have permission to view the full content of this post. Log in or register now.
define('LOGIN_ACTION_URL', 'You do not have permission to view the full content of this post. Log in or register now.
$postValues = array('UserName'=>'sample@gmail.com','Password'=>'samplesample ',''_RequestVerificationToken''=>"");
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, LOGIN_ACTION_URL);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, http_build_query($postValues));
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_COOKIEJAR, cøøkíé_FILE);
curl_setopt($curl, CURLOPT_USERAGENT, USER_AGENT);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_REFERER, LOGIN_FORM_URL);
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, false);
curl_exec($curl);
if(curl_errno($curl)){
throw new Exception(curl_error($curl));
}
//protected page
curl_setopt($curl, CURLOPT_URL, 'You do not have permission to view the full content of this post. Log in or register now.
curl_setopt($curl, CURLOPT_COOKIEJAR, cøøkíé_FILE);
curl_setopt($curl, CURLOPT_USERAGENT, USER_AGENT);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
$output = curl_exec($curl);
curl_close($curl);
echo $output;exit;
define('UserName', 'sample@gmail.com');
define('Password', 'samplesample');
define('_RequestVerificationToken',"'');
define('KeepMeLoggedIn','TRUE');
define('USER_AGENT', 'Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.2309.372 Safari/537.36');
define('cøøkíé_FILE', 'account.txt');
define('LOGIN_FORM_URL', 'You do not have permission to view the full content of this post. Log in or register now.
define('LOGIN_ACTION_URL', 'You do not have permission to view the full content of this post. Log in or register now.
$postValues = array('UserName'=>'sample@gmail.com','Password'=>'samplesample ',''_RequestVerificationToken''=>"");
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, LOGIN_ACTION_URL);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, http_build_query($postValues));
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_COOKIEJAR, cøøkíé_FILE);
curl_setopt($curl, CURLOPT_USERAGENT, USER_AGENT);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_REFERER, LOGIN_FORM_URL);
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, false);
curl_exec($curl);
if(curl_errno($curl)){
throw new Exception(curl_error($curl));
}
//protected page
curl_setopt($curl, CURLOPT_URL, 'You do not have permission to view the full content of this post. Log in or register now.
curl_setopt($curl, CURLOPT_COOKIEJAR, cøøkíé_FILE);
curl_setopt($curl, CURLOPT_USERAGENT, USER_AGENT);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
$output = curl_exec($curl);
curl_close($curl);
echo $output;exit;
Last edited: