moederkoek
Member
- Joined
- Jun 29, 2007
- Sythe Gold
- 0
- Messages
- 49
Had nothing to do so I've made an Automated RuneScape account generator in php, even though I havn't played RS for 2 years
How this works:
There's a .txt file with keywords.
For example you have the keyword "PK"
The script asks the RuneScape database which accounts are available.
It returns "Hex Pk Hope" and creates that account.
The username, password and more stuff is saved in a mysql database.
Because jagex only allows you to make an account each 15 minutes, we'll have to set a cron job to 15 minutes. The script should then create about 35000 accounts/year.
I made this script because I wanted to build an automated character name-selling shop but as I already got a real-life global (lifestyle furniture) company's so dont have the time for some crappy one
--note: I must admit that the code is a bit ugly--
I've removed the script as attachment to prevent ppls abusing and hidden a url
screen of a view created accounts:
data from left to right:
<username><password><birthday><birthyear><birthmonth><countryid><status><date&time created>
How this works:
There's a .txt file with keywords.
For example you have the keyword "PK"
The script asks the RuneScape database which accounts are available.
It returns "Hex Pk Hope" and creates that account.
The username, password and more stuff is saved in a mysql database.
Because jagex only allows you to make an account each 15 minutes, we'll have to set a cron job to 15 minutes. The script should then create about 35000 accounts/year.
I made this script because I wanted to build an automated character name-selling shop but as I already got a real-life global (lifestyle furniture) company's so dont have the time for some crappy one
--note: I must admit that the code is a bit ugly--
I've removed the script as attachment to prevent ppls abusing and hidden a url
PHP:
<?php
//stuff
$dbhost = 'localhost'; //database host, usually localhost
$dbuser = 'username'; //database username
$dbpass = 'userpass'; //database password
$dbname = 'database'; // database name
$search = "search.txt"; //file with keywords
//end stuff
function randomsearch($path){
$words=file($path);
shuffle($words);
return $words[0];
}
function getRSpage($page){
if (!function_exists('curl_init')){
return file_get_contents($page);
}
$curl = curl_init($page);
curl_setopt($curl, CURLOPT_HEADER, false);
curl_setopt($curl, CURLOPT_VERBOSE, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_USERAGENT, false);
$output = curl_exec($curl);
if (curl_errno($curl)){
trigger_error('CURL error: "' . curl_error($curl) . '"', E_USER_WARNING);
$output = false;
}
curl_close($curl);
return $output;
}
function getRSvalue($page){
$value = getRSpage($page);
$value = explode(",", $value);
$value = str_replace(" ","_",$value[1]);
return $value;
}
function cpass() {
$chars = "abcdefghijkmnopqrstuvwxyz0123456789";
srand((double)microtime()*1000000);
$i = 0;
$pass = '' ;
while ($i < 8) {
$num = rand() % 33;
$tmp = substr($chars, $num, 1);
$pass = $pass . $tmp;
$i++;
}
return $pass;
}
//Create values
$pass = cpass();
$asearch = randomsearch($search);
$name = getRSvalue("<hidden>");
$day = rand(1, 28);
$month = rand(1, 11);
$year = rand(1985, 1994);
$country = rand(100, 161);
$exec = getRSpage("<hidden>");
//MYSQL CONNECTING
$connect = mysql_connect("$dbhost", "$dbuser", "$dbpass")
or die ("Could not connect to server :" . mysql_error());
$db = mysql_select_db("$dbname", $connect)
or die ("Could not select db :" . mysql_error());
//CREATE MYSQL TABLE IF NOT EXISTS
$createdb = mysql_query("CREATE TABLE IF NOT EXISTS `account` (
`account` text NOT NULL,
`drowssap` varchar(20) NOT NULL,
`day` tinyint(2) NOT NULL,
`year` text NOT NULL,
`month` tinyint(2) NOT NULL,
`country` text NOT NULL,
`status` tinyint(1) NOT NULL default '0',
`timecreated` timestamp NOT NULL default CURRENT_TIMESTAMP,
KEY `status` (`status`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1");
//INSERT VARS IN DB
$sql = mysql_query("INSERT INTO `".$dbname."`.`account` (`account`, `drowssap`, `day`, `year`, `month`, `country`, `status`) VALUES ('".$name."', '".$pass."', '".$day."', '".$year."', '".$month."', '".$country."', 'NULL')") or die ("Could not insert new data :" . mysql_error());
?>
screen of a view created accounts:
data from left to right:
<username><password><birthday><birthyear><birthmonth><countryid><status><date&time created>
