HaiTang.Library.Api2018k 库调用说明文档
HaiTang.Library.Api2018k 库调用说明文档
概述
HaiTang.Library.Api2018k 是一个用于与 2018k.cn 网络验证系统交互的 .NET 类库,提供软件更新、用户管理、卡密验证、云变量操作、后台管理等功能。
库中包含三个主要部分:
Update类:客户端核心功能,用于获取软件信息、验证卡密、管理用户、操作云变量等。AdminSDK类:后台管理功能,用于登录后台、管理软件、卡密等。Tools工具类:提供机器码生成、加密解密、随机字符串、类型转换等辅助方法。Log日志类:基于 NLog 的简单日志封装,按天输出到文件。
所有异步方法均返回
Task或Task<T>,使用时请使用await或适当方式等待。
命名空间引用
using HaiTang.Library.Api2018k; using HaiTang.Library.Api2018k.SDK; // 后台管理相关
1. Update 类 – 客户端核心功能
1.1 初始化与软件信息
InitializationAsync
初始化软件实例,获取软件配置信息。此方法是后续大多数方法的前置调用。
public async Task<(bool Success, Mysoft? config)> InitializationAsync( string ID, string key, string? Code = null)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
ID | string | 程序实例ID(软件ID),由2018k后台生成 |
key | string | OpenID(开发者密钥),后台获取 |
Code | string? | 机器码,若为 null 将自动调用 Tools.GetMachineCodeEx() 获取本机机器码 |
返回值
Success:是否成功获取有效软件信息(config.author != null)。config:Mysoft对象,包含软件全部信息;若失败则为null。
异常
Exception:网络请求异常或数据解析异常时抛出,但方法内部已捕获并记录日志,返回(false, null)。
示例
// 初始化,使用自动获取的机器码
var update = new Update();
var (success, config) = await update.InitializationAsync("soft123", "your-openid-key");
if (success)
{
Console.WriteLine($"软件名称:{config.softwareName}");
Console.WriteLine($"版本号:{config.versionNumber}");
}
else
{
Console.WriteLine("初始化失败,请检查网络或软件ID");
}
GetSoftCheck [过时]
检查软件实例是否正常。
[Obsolete("合并到InitializationAsync()方法中,2027年01月01日正式禁用此方法", false)]
public async Task<bool> GetSoftCheck()说明此方法已过时,建议直接使用 InitializationAsync 获取完整信息。因为它内部调用 InitializationAsync 并仅返回成功状态。
示例
bool isOk = await update.GetSoftCheck();
获取软件信息的各个属性方法
以下方法均从缓存的 Mysoft 对象中提取特定字段,若缓存失效会自动调用 InitializationAsync 刷新。
| 方法 | 返回值 | 说明 |
|---|---|---|
GetSoftwareID() | Task<string> | 软件实例ID |
GetVersionNumber() | Task<string> | 软件版本号 |
GetSoftwareName() | Task<string> | 软件名称 |
GetVersionInformation() | Task<string> | 版本更新内容 |
GetNotice() | Task<string> | 公告信息 |
GetDownloadLink() | Task<string> | 下载链接 |
GetNumberOfVisits() | Task<string> | 访问量(字符串形式) |
GetMiniVersion() | Task<string> | 最低支持版本号 |
GetIsItEffective() | Task<bool> | 卡密当前是否有效 |
GetExpirationDate() | Task<string> | 卡密过期时间戳(毫秒) |
GetRemarks() | Task<string> | 授权备注 |
GetNumberOfDays() | Task<int> | 授权有效天数(永久为 99999) |
GetNetworkVerificationId() | Task<string> | 卡密ID |
GetTimeStamp() | Task<long> | 服务器时间戳(毫秒) |
GetMandatoryUpdate() | Task<bool> | 是否强制更新 |
GetSoftwareMd5() | Task<string> | 软件 MD5 |
示例
string version = await update.GetVersionNumber();
bool isEffective = await update.GetIsItEffective();
long serverTime = await update.GetTimeStamp();
Console.WriteLine($"当前版本:{version},卡密有效:{isEffective}");
1.2 云变量操作
GetCloudVariables
获取指定云变量的值。
public async Task<string> GetCloudVariables(string VarName)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
VarName | string | 云变量名称 |
返回值变量值字符串;若变量不存在或获取失败,返回常量 "<空>"(_error)。
示例
string bgColor = await update.GetCloudVariables("background_color");
if (bgColor != "<空>")
{
Console.WriteLine($"背景色设置为:{bgColor}");
}
GetCloudVarArray
获取所有云变量,返回一个 JSON 对象。
public async Task<string> GetCloudVarArray()
返回值格式化后的 JSON 字符串,格式如 { "key1": "value1", "key2": "value2" }。
示例
string allVars = await update.GetCloudVarArray();
Console.WriteLine(allVars);
// 输出:
// {
// "welcome_message": "欢迎使用",
// "max_users": "100"
// }
updateCloudVariables
修改或新增云变量。
public async Task<(bool success, string message)> updateCloudVariables( string VarKey, string Value)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
VarKey | string | 变量名 |
Value | string | 要设置的值 |
返回值
success:操作是否成功。message:成功时返回设置的键值对 JSON(如{"key":"bg_color","value":"blue"}),失败时返回错误信息。
示例
var (ok, msg) = await update.updateCloudVariables("theme", "dark");
if (ok)
{
Console.WriteLine("云变量更新成功:" + msg);
}
else
{
Console.WriteLine("更新失败:" + msg);
}
1.3 卡密操作
ActivationKey
激活卡密(绑定当前机器码)。
public async Task<(bool success, string message)> ActivationKey(string authId)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
authId | string | 卡密ID(从后台获取或用户输入) |
返回值
success:是否激活成功。message:成功返回“授权成功”,失败返回错误原因。
示例
var (ok, msg) = await update.ActivationKey("1CDEB2CC3F414E84BA894655E753194C");
if (ok)
{
MessageBox.Show("激活成功!");
}
else
{
MessageBox.Show("激活失败:" + msg);
}
CreateNetworkAuthentication
创建卡密(需要管理员权限,通常用于后台自动生成)。
public async Task<string> CreateNetworkAuthentication(int day, string remark, string ID)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
day | int | 有效天数(例如 30 表示30天,若要永久可尝试传入 0 或 99999,但需确认后端支持) |
remark | string | 卡密备注 |
ID | string | 程序实例ID(软件ID) |
返回值格式化的 JSON 字符串,包含新创建的卡密信息,如:
{
"code": 200,
"data": "1CDEB2CC3F414E84BA894655E753194C",
"message": "请求成功"
}
示例
string result = await update.CreateNetworkAuthentication(30, "测试卡密", "soft123"); Console.WriteLine(result);
ReplaceBind
解绑或换绑机器码。
public async Task<(bool success, string message)> ReplaceBind( string AuthId, string? Code = null)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
AuthId | string | 卡密ID |
Code | string? | 新机器码;若为 null 则执行解绑(清除绑定的机器码) |
返回值
success:操作是否成功。message:成功返回“解|换绑成功”,失败返回错误信息。
示例
// 解绑
var (ok1, msg1) = await update.ReplaceBind("AUTH-123456");
// 换绑到新机器码
string newCode = Tools.GetMachineCodeEx();
var (ok2, msg2) = await update.ReplaceBind("AUTH-123456", newCode);
GetRemainingUsageTime
获取卡密剩余使用时间。
public async Task<long> GetRemainingUsageTime()
返回值
-1:永久有效。0:已过期。1:未注册(无有效卡密或未激活)。>0:剩余毫秒数。
示例
long remaining = await update.GetRemainingUsageTime();
if (remaining == -1)
Console.WriteLine("永久授权");
else if (remaining == 0)
Console.WriteLine("已过期");
else if (remaining == 1)
Console.WriteLine("未注册");
else
Console.WriteLine($"剩余:{TimeSpan.FromMilliseconds(remaining).TotalDays:F1} 天");
GetNetworkCode
获取验证码(用于用户注册等需要验证码的场合)。
public async Task<string> GetNetworkCode()
返回值验证码字符串(例如 "8A3F")。
示例
string captcha = await update.GetNetworkCode();
Console.WriteLine("验证码:" + captcha);
1.4 用户相关方法
CustomerRegister
注册新用户。
public async Task<bool> CustomerRegister( string email, string password, string? nickName = null, string? avatarUrl = null, string? captcha = null)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
email | string | 用户邮箱(作为登录账号) |
password | string | 密码 |
nickName | string? | 昵称(可选) |
avatarUrl | string? | 头像地址(可选) |
captcha | string? | 验证码(可选,需要时从 GetNetworkCode() 获取) |
返回值注册成功返回 true,否则 false。
示例
bool regOk = await update.CustomerRegister(
email: "user@haitangyunchi.com",
password: "123456",
nickName: "测试用户",
captcha: await update.GetNetworkCode()
);
if (regOk)
Console.WriteLine("注册成功");
InitializationUserAsync
初始化用户会话,获取用户信息。后续用户相关方法需先调用此方法(或确保 Constants.EMAIL 和 Constants.PASSWORD 已设置)。
public async Task<UserInfo> InitializationUserAsync( string ID, string key, string email, string password)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
ID | string | 软件ID |
key | string | OpenID |
email | string | 用户邮箱 |
password | string | 用户密码 |
返回值UserInfo 对象;若失败则返回空对象(所有字段为空)。
示例
UserInfo user = await update.InitializationUserAsync("soft123", "your-key", "user@haitangyunchi.com", "pass");
if (!string.IsNullOrEmpty(user.CustomerId))
{
Console.WriteLine($"欢迎 {user.Nickname}");
}
GetUserInfo
获取当前已初始化用户的完整信息。
public async Task<UserInfo> GetUserInfo()
返回值UserInfo 对象(若未初始化,返回空对象)。
示例
UserInfo info = await update.GetUserInfo();
Console.WriteLine($"用户ID:{info.CustomerId}");
用户信息属性获取方法
以下方法均从 UserInfo 缓存中提取特定字段。
| 方法 | 返回值 | 说明 |
|---|---|---|
GetUserId() | Task<string> | 用户ID |
GetUserAvatar() | Task<string> | 用户头像URL |
GetUserNickname() | Task<string> | 用户昵称 |
GetUserEmail() | Task<string> | 用户邮箱 |
GetUserBalance() | Task<int> | 账户余额/剩余天数(需根据业务含义) |
GetUserLicense() | Task<bool> | 是否已授权(License == "y") |
GetUserTimeCrypt() | Task<string> | 登录时间戳 |
示例
string uid = await update.GetUserId(); int balance = await update.GetUserBalance(); bool licensed = await update.GetUserLicense();
Recharge
使用卡密为用户充值(增加账户余额/有效期)。
public async Task<string> Recharge(string AuthId)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
AuthId | string | 卡密ID |
返回值接口返回的原始 JSON 字符串。
示例
string rechargeResult = await update.Recharge("8B5F075DDB2148EFA38E58AA9790CB40");
Console.WriteLine(rechargeResult);
1.5 消息发送
MessageSend
发送一条消息到服务器(可用于记录日志或向开发者发送通知)。
public async Task<string> MessageSend(string message)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
message | string | 要发送的消息内容 |
返回值格式化的 JSON 响应。
示例
string response = await update.MessageSend("用户点击了开始按钮");
Console.WriteLine(response);
1.6 缓存控制静态方法
这些方法用于操作 Update 类内部的静态缓存(软件信息、用户信息),通常不需要手动调用,除非需要强制刷新。
| 方法 | 说明 |
|---|---|
GetCachedSoftwareInfo() | 获取缓存的软件信息对象 |
SetCachedSoftwareInfo(bool success, Mysoft softwareInfo) | 设置软件信息缓存 |
IsCacheValid() | 检查软件信息缓存是否有效(5分钟内) |
ClearStaticCache() | 清除软件信息缓存 |
GetCachedUserInfo() | 获取缓存的用户信息对象 |
SetCachedUserInfo(UserInfo userInfo) | 设置用户信息缓存 |
IsUserCacheValid() | 检查用户信息缓存是否有效(5分钟内) |
ClearUserCache() | 清除用户信息缓存 |
示例
// 强制清除缓存,下次获取时会重新请求网络 Update.ClearStaticCache(); Update.ClearUserCache();
2. AdminSDK 类 – 后台管理功能
所有方法必须先调用
LoginAsync成功登录,否则会抛出InvalidOperationException。
LoginAsync
登录后台管理系统。
public async Task<(bool Success, string Message)> LoginAsync(string account, string password)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
account | string | 后台账号 |
password | string | 密码 |
返回值
Success:登录是否成功。Message:成功时返回 Token(会自动保存在Token属性中),失败时返回错误信息。
示例
var admin = new AdminSDK();
var (ok, token) = await admin.LoginAsync("admin", "123456");
if (ok)
{
Console.WriteLine("登录成功,Token:" + token);
}
GetSoftwareIdsAsync
获取软件ID列表。
public async Task<List<string>> GetSoftwareIdsAsync(long maxCount = 10)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
maxCount | long | 最大返回数量(默认10) |
返回值软件ID字符串列表。
示例
List<string> ids = await admin.GetSoftwareIdsAsync(20);
foreach (string id in ids)
{
Console.WriteLine(id);
}
GetSoftwareInfoByIdAsync
根据软件ID获取详细信息。
public async Task<SoftwareInfo> GetSoftwareInfoByIdAsync( string softwareId, long maxCount = 10)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
softwareId | string | 软件ID |
maxCount | long | 最大查询数量(用于翻页) |
返回值SoftwareInfo 对象,包含软件名称、版本、访问量、下载链接等。
示例
SoftwareInfo info = await admin.GetSoftwareInfoByIdAsync("soft123");
Console.WriteLine($"软件名:{info.SoftwareName},版本:{info.SoftwareVersion}");
GetCardListAsync
获取卡密列表。
public async Task<List<CardInfo>> GetCardListAsync( string? softwareId = null, long maxCount = 50)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
softwareId | string? | 筛选指定软件的卡密,为 null 则返回所有 |
maxCount | long | 最大返回数量(默认50) |
返回值List<CardInfo>,每个元素包含卡号、状态、机器码、备注、有效期等。
示例
// 获取所有卡密
List<CardInfo> allCards = await admin.GetCardListAsync();
// 获取指定软件的卡密
List<CardInfo> softCards = await admin.GetCardListAsync("soft123");
foreach (var card in softCards)
{
Console.WriteLine($"{card.CardNumber} - 激活:{card.IsActivated}");
}
CreateCardAsync
批量创建卡密。
public async Task<(bool Success, List<string> CreatedCards)> CreateCardAsync( string softwareId, string remarks, int duration, int count)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
softwareId | string | 软件ID |
remarks | string | 备注 |
duration | int | 有效天数(0 表示永久) |
count | int | 创建数量 |
返回值
Success:操作是否成功。CreatedCards:新生成的卡密列表。
示例
var (ok, cards) = await admin.CreateCardAsync("soft123", "测试卡密", 30, 5);
if (ok)
{
Console.WriteLine("生成的卡密:");
foreach (string c in cards) Console.WriteLine(c);
}
CreateSoftwareAsync
创建新软件。
public async Task<bool> CreateSoftwareAsync(string name, string version)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
name | string | 软件名称 |
version | string | 初始版本号 |
返回值成功返回 true,失败返回 false。
示例
bool created = await admin.CreateSoftwareAsync("我的软件", "1.0.0");
Console.WriteLine(created ? "创建成功" : "创建失败");
EditSoftwareInfoAsync [未实现]
编辑软件信息(预留接口)。
public async Task<bool> EditSoftwareInfoAsync(string id, SoftwareInfo updatedInfo)
注意:此方法目前抛出
NotImplementedException,请根据实际后端接口自行实现。
数据模型(AdminSDK)
SoftwareInfo
| 属性 | 类型 | 说明 |
|---|---|---|
SoftwareName | string | 软件名称 |
SoftwareVersion | string | 版本号 |
VisitCount | string | 访问量 |
UpdateContent | string | 更新内容 |
LowVersion | string | 强制更新版本(最低版本) |
Md5 | string | 文件 MD5 |
CreateTime | string | 创建时间 |
DownloadUrl | string | 下载链接 |
ForceUpdate | bool | 是否强制更新 |
Id | string | 软件ID |
CardInfo
| 属性 | 类型 | 说明 |
|---|---|---|
CardNumber | string | 卡密编号 |
IsActivated | bool | 是否已激活 |
MachineCode | string | 绑定的机器码 |
Remarks | string | 备注 |
Duration | string | 有效天数 |
SoftwareId | string | 所属软件ID |
3. Tools 工具类
3.1 机器码
GetMachineCode [过时]
获取格式化的 20 位机器码(CPU+主板+盐值)。
[Obsolete("请使用 GetMachineCodeEx() 以获得更好的机器码,2027年01月01日正式禁用此方法", false)]
public static string GetMachineCode()
返回值格式:XXXXX-XXXXX-XXXXX-XXXXX-XXXXX。
示例
string oldCode = Tools.GetMachineCode(); // 例如 "AB12C-DE34F-GH56I-JK78L-MN90P"
GetMachineCodeEx
获取更安全的 128 位(SHA512)机器码。
public static string GetMachineCodeEx()
返回值128 字符十六进制字符串。
示例
string machineCode = Tools.GetMachineCodeEx(); Console.WriteLine(machineCode); // 输出类似 "9F86D081884C7D659A2FEAA0C55AD015A3BF4F1B2B0B822CD15D6C15B0F00A08..."
3.2 随机字符串与盐值
GenerateRandomString
生成指定类型和长度的随机字符串。
public static string GenerateRandomString(int length, int type = 0)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
length | int | 长度 |
type | int | 类型:0=字母数字(默认),1=字母,2=数字,3=大写字母,4=大写字母+数字 |
返回值随机字符串。
示例
string code = Tools.GenerateRandomString(8, 4); // 8位大写字母+数字,如 "A3F9B2K1" string password = Tools.GenerateRandomString(12, 0); // 12位混合字符
GenerateSalt
生成密码学安全的随机盐值(Base64)。
public static string GenerateSalt(int length = 64)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
length | int | 随机字节长度(默认64,) |
返回值Base64 编码的盐值。
示例
string salt = Tools.GenerateSalt(); // 生成64字符的Base64字符串 string customSalt = Tools.GenerateSalt(32); // 生成32字符的Base64字符串
3.3 哈希
Sha256
计算字符串的 SHA-256 哈希值(十六进制大写)。
public static string Sha256(string input)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
input | string | 输入字符串 |
返回值64 字符的十六进制字符串。
示例
string hash = Tools.Sha256("hello");
Console.WriteLine(hash); // 2CF24DBA5FB0A30E26E83B2AC5B9E29E1B161E5C1FA7425E73043362938B9824
Sha512
计算字符串的 SHA-512 哈希值(十六进制大写)。
public static string Sha512(string input)
返回值128 字符的十六进制字符串。
示例
string hash = Tools.Sha512("hello");
Console.WriteLine(hash); // 9B71D224BD62F3785D96D46AD3EA3D73319BFBC2890CAADAE2DFF72519673CA72323C3D99BA5C11D7C7ACC6E...
3.4 加密解密
使用十六进制密钥的 AES 加密/解密
密钥必须为 32 字节的十六进制字符串(64字符),例如由 Tools.Sha256("password") 生成。
public static string Encrypt(string plainText, string key) public static string Decrypt(string cipherText, string key)
参数
plainText:明文。cipherText:Base64 密文(包含16字节随机IV)。key:32字节十六进制密钥(64字符)。
返回值加密返回 Base64 字符串,解密返回明文。
示例
string key = Tools.Sha256("mySecretKey"); // 64字符十六进制
string encrypted = Tools.Encrypt("敏感数据", key);
Console.WriteLine(encrypted);
string decrypted = Tools.Decrypt(encrypted, key);
Console.WriteLine(decrypted); // 输出 "敏感数据"
使用密码+盐值的 AES 加密/解密(PBKDF2派生密钥)
更安全的加密方式,推荐用于用户密码加密。
public static string Encrypt(string plainText, string password, string salt) public static string Decrypt(string cipherText, string password, string salt)
参数
password:用户提供的密码。salt:盐值(建议使用GenerateSalt()生成)。其他同前。
示例
string password = "userPass123";
string salt = Tools.GenerateSalt();
string encrypted = Tools.Encrypt("秘密信息", password, salt);
string decrypted = Tools.Decrypt(encrypted, password, salt);
3.5 类型转换
ToBoolean
将多种常见字符串转换为布尔值。
public static bool ToBoolean(string value, out bool result)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
value | string | 输入字符串 |
result | out bool | 转换成功后的布尔值 |
返回值true 表示转换成功,false 表示无法识别。
支持的值(不区分大小写)
真:
true,1,yes,y,on,enable,enabled,active,t,ok,okay,correct,right,positive,affirmative,aye,si,da,ja,はい,是,真,✓,√假:
false,0,no,n,off,disable,disabled,inactive,f,cancel,wrong,incorrect,negative,nay,no way,non,nein,нет,いいえ,否,假,✗,×
示例
if (Tools.ToBoolean("yes", out bool b1)) Console.WriteLine(b1); // True
if (Tools.ToBoolean("0", out bool b2)) Console.WriteLine(b2); // False
if (Tools.ToBoolean("maybe", out bool b3)) { } else Console.WriteLine("无法转换");
3.6 更新程序
upgrade
启动外部更新程序 upgrade.exe 进行软件更新。
public static void upgrade(string downloadUrl)
参数
| 名称 | 类型 | 说明 |
|---|---|---|
downloadUrl | string | 新版本下载地址 |
说明需要在程序目录下放置 upgrade.exe,该程序将接收下载地址和当前进程路径作为参数。
若 upgrade.exe 不存在,方法静默返回。
示例
string downloadUrl = await update.GetDownloadLink(); Tools.upgrade(downloadUrl); // 启动更新程序后,当前进程应尽快退出 Environment.Exit(0);
4. Log 日志类
基于 NLog 的静态日志类,日志文件保存在 应用程序根目录/Logs/yyyy-MM-dd.log。
方法
| 方法 | 说明 |
|---|---|
Debug(string message) | 记录调试信息 |
Info(string message) | 记录一般信息 |
Warn(string message) | 记录警告 |
Error(string message) | 记录错误 |
Error(Exception ex, string message) | 记录错误及异常详情 |
Fatal(string message) | 记录致命错误 |
示例
Log.Info("应用程序启动");
try
{
// 业务代码
}
catch (Exception ex)
{
Log.Error(ex, "操作失败");
}
附录:常用数据模型
Mysoft (软件信息)
| 属性 | 类型 | 说明 |
|---|---|---|
author | string | 作者 |
softwareMd5 | string | 软件 MD5 |
softwareName | string | 软件名称 |
softwareId | string | 软件ID |
versionNumber | string | 版本号 |
mandatoryUpdate | bool | 是否强制更新 |
numberOfVisits | int | 访问量 |
miniVersion | string | 最低版本 |
timeStamp | long | 服务器时间戳 |
networkVerificationId | string | 卡密ID |
isItEffective | bool | 卡密是否有效 |
numberOfDays | int | 有效天数 |
networkVerificationRemarks | string | 授权备注 |
expirationDate | long | 过期时间戳 |
downloadLink | string | 下载链接 |
notice | string | 公告 |
versionInformation | string | 更新内容 |
bilibiliLink | string | B站链接(固定值) |
UserInfo (用户信息)
| 属性 | 类型 | 说明 |
|---|---|---|
CustomerId | string | 用户ID |
AvatarUrl | string | 头像URL |
Nickname | string | 昵称 |
Email | string | 邮箱 |
Balance | int | 余额/剩余天数 |
License | string | 授权标识( true/ false) |
TimeCrypt | string | 登录时间戳 |
Timestamp | long | 服务器时间戳 |