Dear All,
I was wondering if it was possible to use PHP and login to another site and it installs cookies/sessions on the php script and lets it stay loggedin to get data. Basicly a way the PHP can parse a page that you have to be loggedin to see it.
Cookies/Sessions
Moderator: General Moderators
Of coarse it is possible, however, doing it from scratch is very tedious, I'm not really sure, but I think Curl (cUrl?) is capable of keeping track of sessions, cookies etc for such things.
If Curl is not what you are looking for (or possible solution) then I am most positively certain that such a project already exists on the internet which can accomplish this.
If Curl is not what you are looking for (or possible solution) then I am most positively certain that such a project already exists on the internet which can accomplish this.
-
malcolmboston
- DevNet Resident
- Posts: 1826
- Joined: Tue Nov 18, 2003 1:09 pm
- Location: Middlesbrough, UK
exploits? like what?The Hidden Viper wrote:Awsome thank you very much, I play online MMORPG's and I wanted to try to make a PHP file that actaully had maby a iframe of some sorte with the site on it. and at the top of my iframe it had tons of features
to do things on the site, any exploits .ect it could do. Basicly like a cheat. Thanks alot
you could find yourself in serious trouble, 99.999% of EULA's have this covered, and believe me, they can take you 'to the full extent of the law'
Code: Select all
<?php
########################
# ********** Hack v1.0
########################
$domain = "**********.***";
$username = "iamcool";
$password = "bVVStkMnS4";
$params = "uid=" . $username . "&pword=" . $password;
$socket = fsockopen($domain,80);
fputs($socket,"POST login_scripts/login.php HTTP/1.1\r\n");
fputs($socket,"Referer: BH\r\n");
fputs($socket,"Host: Host\r\n");
fputs($socket,"Accept: text/html\r\n");
fputs($socket,"User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)\r\n");
fputs($socket,"Content-type: application/x-www-form-urlencoded\r\n");
fputs($socket,"Content-length: " . $params . "\r\n");
fputs($socket,"Connection: Close\r\n");
fputs($socket,"\r\n");
fputs($socket,$variables."\r\n");
while(!feof($socket)){
$a = fgets($socket,256);
if ($a){
echo $a."<br>";
}
}
?>