diff --git a/src/config.lua b/src/config.lua index c7b27b3..8ac635c 100644 --- a/src/config.lua +++ b/src/config.lua @@ -2,7 +2,7 @@ local user = { usr = "201413640731", -- 在这里输入用户名 pwd = "yourpasswd", -- 在这里输入密码 - net = 1, -- 网络类型,0: 校园网,1: 互联网 + net = "SNET", -- 网络类型,SNET: 校园网(school net),INET: 互联网(internet),默认为SNET } -- 软件设置 diff --git a/src/core.lua b/src/core.lua index 3273c61..285c57a 100644 --- a/src/core.lua +++ b/src/core.lua @@ -25,7 +25,7 @@ local table2string = function(tb) end local body = { - ["DDDDD"] = (user.net == 0) and user.usr or user.usr.."@tel", + ["DDDDD"] = (user.net == "SNET") and user.usr or user.usr.."@tel", ["upass"] = encryt_pwd(user.pwd), ["R1"] = 0, ["R2"] = 1, @@ -38,7 +38,7 @@ local resbody = {} -- 开始请求 local function login() - print(("User(%s) Logining..."):format(user.usr)) + print(("User(%s) Logining..."):format(body["DDDDD"])) local res, code, reshd = http.request({ url = syscfg.url, method = "POST",