mirror of
https://github.com/BTMuli/TeyvatGuide.git
synced 2025-12-12 09:18:14 +08:00
♻️ 完善 fp 获取,添加强制更新入口
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/**
|
||||
* @file src/web/request/getDeviceFp.ts
|
||||
* @description 获取设备指纹
|
||||
* @since Beta v0.3.6
|
||||
* @since Beta v0.4.1
|
||||
*/
|
||||
|
||||
import { http } from "@tauri-apps/api";
|
||||
@@ -11,7 +11,7 @@ import TGConstant from "../constant/TGConstant";
|
||||
|
||||
/**
|
||||
* @description 获取设备指纹
|
||||
* @since Beta v0.3.6
|
||||
* @since Beta v0.4.1
|
||||
* @param {TGApp.App.Device.DeviceInfo} Info - 设备信息
|
||||
* @returns {Promise<string>} 设备指纹
|
||||
*/
|
||||
@@ -20,38 +20,59 @@ export async function getDeviceFp(
|
||||
): Promise<TGApp.App.Device.DeviceInfo> {
|
||||
const info = Info ?? getInitDeviceInfo();
|
||||
const deviceFPHeader = {
|
||||
cpuType: "arm64-v8a",
|
||||
proxyStatus: 0,
|
||||
isRoot: 0,
|
||||
romCapacity: "512",
|
||||
productName: info.model,
|
||||
romRemain: "256",
|
||||
manufacturer: "Xiaomi",
|
||||
appMemory: "512",
|
||||
deviceName: info.device_name,
|
||||
productName: info.product,
|
||||
romRemain: "512",
|
||||
hostname: "dg02-pool03-kvm87",
|
||||
screenSize: "1080x1920",
|
||||
osVersion: "13",
|
||||
screenSize: "1440x2905",
|
||||
isTablet: 0,
|
||||
aaid: "",
|
||||
vendor: "中国移动",
|
||||
accelerometer: "true",
|
||||
buildTags: "release-keys",
|
||||
model: info.model,
|
||||
model: info.device_name,
|
||||
brand: "Xiaomi",
|
||||
oaid: "",
|
||||
hardware: "qcom",
|
||||
deviceType: "OP5913L1",
|
||||
devId: "unknown",
|
||||
serialNumber: "unknown",
|
||||
buildTime: "1588876800000", // 2020-05-08
|
||||
buildUser: "root",
|
||||
ramCapacity: "2048",
|
||||
magnetometer: "true",
|
||||
display: `OP5913L1-user ${info.model} 10 QKQ1.190825.002 V12.0.1.0.QFJCNXM release-keys`,
|
||||
ramRemain: "1024",
|
||||
deviceInfo: "unknown",
|
||||
gyroscope: "true",
|
||||
sdCardCapacity: 512215,
|
||||
buildTime: "1693626947000",
|
||||
buildUser: "android-build",
|
||||
simState: "5",
|
||||
ramRemain: "239814",
|
||||
appUpdateTimeDiff: 1702604034882,
|
||||
deviceInfo: `XiaoMi ${info.device_name} OP5913L1:13 SKQ1.221119.001 T.118e6c7-5aa23-73911:user release-keys`,
|
||||
vaid: "",
|
||||
buildType: "user",
|
||||
sdkVersion: "29",
|
||||
board: "sdm660",
|
||||
sdkVersion: "34",
|
||||
ui_mode: "UI_MODE_TYPE_NORMAL",
|
||||
isMockLocation: 0,
|
||||
cpuType: "arm64-v8a",
|
||||
isAirMode: 0,
|
||||
ringMode: 2,
|
||||
chargeStatus: 1,
|
||||
manufacturer: "XiaoMi",
|
||||
emulatorStatus: 0,
|
||||
appMemory: "512",
|
||||
osVersion: "14",
|
||||
vendor: "unknown",
|
||||
accelerometer: "1.4883357x9.80665x-0.1963501", // 这边与 hutao 数据不一致
|
||||
sdRemain: 239600,
|
||||
buildTags: "release-keys",
|
||||
packageName: "com.mihoyo.hyperion",
|
||||
networkType: "WiFi",
|
||||
oaid: "",
|
||||
debugStatus: 1,
|
||||
ramCapacity: "469679",
|
||||
magnetometer: "20.081251x-27.457501x2.1937501",
|
||||
display: `${info.product}_13.1.0.181(CN01)`,
|
||||
appInstallTimeDiff: 1688455751496,
|
||||
packageVersion: "2.20.1",
|
||||
gyroscope: "0.030226856x-0.014647375x-0.0013732915", // 这边与 hutao 数据不一致
|
||||
batteryStatus: 100,
|
||||
hasKeyboard: 0,
|
||||
board: "taro",
|
||||
};
|
||||
const url = "https://public-data-api.mihoyo.com/device-fp/api/getFp";
|
||||
const data = {
|
||||
|
||||
Reference in New Issue
Block a user