|
import requests |
|
import sys |
|
import random |
|
import argparse |
|
import json |
|
|
|
url = "https://www.roblox.com/mobileapi/userinfo" |
|
|
|
preface = "WARNING:-DO-NOT-SHARE-THIS.--Sharing-this-will-allow-someone-to-log-in-as-you-and-to-steal-your-ROBUX-and-items." |
|
headers = { |
|
'Cookies': '', |
|
"Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9", |
|
"Accept-language": "pl-PL,pl;q=0.9,en-US;q=0.8,en;q=0.7", |
|
"Cache-control": "max-age=0", |
|
"Sec-ch-ua": "\"Chromium\";v=\"94\", \" Not A;Brand\";v=\"99\", \"Opera GX\";v=\"80\"", |
|
"Sec-ch-ua-mobile": "?0", |
|
"Sec-ch-ua-platform": "\"Windows\"", |
|
"Sec-fetch-dest": "document", |
|
"Sec-fetch-mode": "navigate", |
|
"Sec-fetch-site": "same-origin", |
|
"Sec-fetch-user": "?1", |
|
"Upgrade-insecure-requests": "1", |
|
} |
|
|
|
|
|
|
|
|
|
print() |
|
|
|
parser = argparse.ArgumentParser(description='get cookie identity.') |
|
|
|
parser.add_argument('-cv', type=str, default=None, |
|
help='cookie to verify') |
|
|
|
|
|
|
|
if __name__ == "__main__": |
|
|
|
args = parser.parse_args() |
|
if args.cv is None: |
|
print("no cookie provided") |
|
sys.exit() |
|
|
|
cvalue = "_|{}|_{}".format(preface, args.cv) |
|
|
|
agents = ['Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/37.0.2062.94 Chrome/37.0.2062.94 Safari/537.36', 'Mozilla/5.0 (iPad; CPU OS 8_3 like Mac OS X) AppleWebKit/600.1.4 (KHTML, like Gecko) Version/8.0 Mobile/12F69 Safari/600.1.4'] |
|
headers['User-agent'] = random.choice(agents) |
|
|
|
with requests.session() as session: |
|
session.cookies['.ROBLOSECURITY'] = cvalue |
|
for k, v in headers.items(): |
|
session.headers[k] = v |
|
|
|
rsp = session.get(url, headers=headers, allow_redirects=False) |
|
if rsp.status_code != 200: |
|
print ("Invalid") |
|
else: |
|
print(json.dumps(rsp.json(), indent=4)) |