SRL Archive - Python/Perl Help and Tutorials

Runescape Account Creator [Python]


bobng

2008-11-19 16:26:53

Creates an account for runescape. Randomly chooses a non-existing account name and a password you choose, or it can find a username you like (If you like the name rofl, it will append numbers to that username until it finds one that is not in use - i.e rofl124155)

Requires:
Python 2.5
Clientform:
http://wwwsearch.sourceforge.net/ClientForm/#download


# Account creator
import urllib
from urllib2 import urlopen
from ClientForm import ParseResponse
import random
url = 'https://create.runescape.com/index.ws'
api_url = 'https://create.runescape.com/checkusername.ajax?username='
a = raw_input('Type a username here. Put nothing for a random one ')
password = raw_input('Type a password for the account. Must be over 5 characters ')
findstring = 'has now been created with the password you have chosen. We recommend you make a note of it on a bit of paper and keep it somewhere <strong>really</strong> safe, in case you forget it.</p>'
used_usernames = ['ox',
'lol',
'ownage',
'killer']

def make_username(username):
# Lets check if its blank
if username == '':
# Choose a random used username out of the list
check_name = random.choice(used_usernames)
z = username_get(check_name).split(',')
# Split the string into a list of usernames
# Choose a random one!
jew = random.choice(z)
print 'Username chosen: %s'%jew
return jew
else:
# Check if the username is in use allready:
if username_check(username):
# Not in use!
return username
else:
print username+' is in use. Finding a match closest to it'
a = 0
while 1:
a = random.randint(a,a+100)
check_name = username+str(a)
if username_check(check_name):
break
print check_name+' in use - trying another'
print check_name+' not in use! - using'
return check_name

def username_check(username):
if urllib.urlopen(api_url+username).read() == '17':
return True
else:
return False
def username_get(username):
return urllib.urlopen(api_url+username).read().replace('18,','')

username = make_username(a)

country = "88"
response = urlopen(url)
forms = ParseResponse(response,backwards_compat=False)
form = forms[0]
form['username'] = username
form['password1'] = password
form['password2'] = password
form['day'] = [str(random.randint(1,31))]
form['month'] = [str(random.randint(0,11))]
form['year'] = str(random.randint(1950,1990))
form['country'] = ["225"]
form['agree_privacy'] = ['on']
form['agree_terms'] = ['on']
print '---------------------'
print 'Details:'
print 'Username: %s'%username
print 'Password: %s'%password
print '---------------------'
print ' '
print 'Creating account...'
form.click()
print 'Account created'
while 1:
pass

Starbridge

2009-01-31 12:38:52

Sweet, this is just what I need, but, could you compile it? I don't have a compiler… *googles away*

Cowie`

2009-02-13 19:43:37

Why not just use a direct link for the account creation rather than the form? It's alot easier and you can just replace the args with your functions.

NxTitle

2009-06-22 21:54:05

Uh… you don't need to compile python, it does it automatically, just put that into a .py file and run it in the python interpreter

ian.

2009-06-22 22:09:09

I don't think they're worried about that anymore, NxTitle..

Brandon W

2009-07-02 14:10:46

This just doesn't want to run for me :S

brandon-warwicks-mac-mini:~ Brandon$ cd '/Users/Brandon/Desktop/' && '/usr/bin/pythonw'  '/Users/Brandon/Desktop/create.py'  && echo Exit status: $? && exit 1
Traceback (most recent call last):
File "/Users/Brandon/Desktop/create.py", line 4, in <module>
from ClientForm import ParseResponse
ImportError: No module named ClientForm

EDIT: Wait… Is this for 2.6 or 3?

Gu3st...

2009-07-02 15:01:49

From: Brandon W
This just doesn't want to run for me :S

brandon-warwicks-mac-mini:~ Brandon$ cd '/Users/Brandon/Desktop/' && '/usr/bin/pythonw'  '/Users/Brandon/Desktop/create.py'  && echo Exit status: $? && exit 1
Traceback (most recent call last):
File "/Users/Brandon/Desktop/create.py", line 4, in <module>
from ClientForm import ParseResponse
ImportError: No module named ClientForm
EDIT: Wait… Is this for 2.6 or 3?

As he said in the first post:
Requires:
Python 2.5
Clientform:
http://wwwsearch.sourceforge.net/ClientForm/#download

I am pretty sure it's 2.5 :p

mistachocolata99

2014-09-01 13:49:33

hi could osmoene help me with this?

Wetish

2014-09-01 13:55:59

From: mistachocolata99
hi could osmoene help me with this?


This is from 2009. It is very outdated and not working. Sorry :(

mistachocolata99

2014-09-01 13:58:51

oh :(