From 5215e7902d22d34e90f47cdc2543aa501ef54ddb Mon Sep 17 00:00:00 2001 From: baiqwerdvd <158065462+baiqwerdvd@users.noreply.github.com> Date: Mon, 9 Dec 2024 16:23:55 +0800 Subject: [PATCH] 111111 --- ArknightsUID/arknightsuid_login/login.py | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/ArknightsUID/arknightsuid_login/login.py b/ArknightsUID/arknightsuid_login/login.py index 2c5d812..3c5a032 100644 --- a/ArknightsUID/arknightsuid_login/login.py +++ b/ArknightsUID/arknightsuid_login/login.py @@ -180,13 +180,17 @@ class SklandLogin: self.ark_uid: str = result_data["data"]["uid"] async def generate_cred_by_code(self): - self.client.headers["platform"] = "1" - self.client.headers["vName"] = "1.28.0" - self.client.headers["origin"] = "https://zonai.skland.com/" - self.client.headers["referer"] = "https://zonai.skland.com/" - self.client.headers["sign_enable"] = False - self.client.headers["dId"] = await get_d_id() - self.client.headers["timestamp"] = str(int(datetime.now().timestamp())) + headers = { + "User-Agent": "Skland/1.28.0 (com.hypergryph.skland; build:102800063; Android 35; ) Okhttp/4.11.0", + "platform": "1", + "vName": "1.28.0", + "origin": "https://zonai.skland.com/", + "referer": "https://zonai.skland.com/", + "sign_enable": False, + "dId": await get_d_id(), + "timestamp": str(int(datetime.now().timestamp())), + } + self.client.headers = headers response = self.client.post( GENERATE_CRED_BY_CODE, json={"code": self.code, "kind": 1},