| 68 | url = f'https://api.cloudflareclient.com/v0a{digitString(3)}/reg' |
| 69 | |
| 70 | def run(): |
| 71 | try: |
| 72 | install_id = genString(22) |
| 73 | body = {"key": "{}=".format(genString(43)), |
| 74 | "install_id": install_id, |
| 75 | "fcm_token": "{}:APA91b{}".format(install_id, genString(134)), |
| 76 | "referrer": referrer, |
| 77 | "warp_enabled": False, |
| 78 | "tos": datetime.datetime.now().isoformat()[:-3] + "+02:00", |
| 79 | "type": "Android", |
| 80 | "locale": "es_ES"} |
| 81 | data = json.dumps(body).encode('utf8') |
| 82 | headers = {'Content-Type': 'application/json; charset=UTF-8', |
| 83 | 'Host': 'api.cloudflareclient.com', |
| 84 | 'Connection': 'Keep-Alive', |
| 85 | 'Accept-Encoding': 'gzip', |
| 86 | 'User-Agent': 'okhttp/3.12.1' |
| 87 | } |
| 88 | req = urllib.request.Request(url, data, headers) |
| 89 | response = urllib.request.urlopen(req) |
| 90 | status_code = response.getcode() |
| 91 | return status_code |
| 92 | except Exception as error: |
| 93 | print(error) |
| 94 | |
| 95 | g = 0 |
| 96 | b = 0 |