1
0
mirror of https://shylinux.com/x/icebergs synced 2025-04-26 01:24:05 +08:00
This commit is contained in:
harveyshao 2022-11-13 14:52:46 +08:00
parent 398be22600
commit 7addfa5581

View File

@ -281,11 +281,7 @@ func _serve_handle(key string, cmd *ice.Command, msg *ice.Message, w http.Respon
}
func _serve_login(msg *ice.Message, key string, cmds []string, w http.ResponseWriter, r *http.Request) ([]string, bool) {
aaa.SessCheck(msg, msg.Option(ice.MSG_SESSID)) // 会话认证
if msg.Config("staffname") != "" {
aaa.UserLogin(msg, r.Header.Get("Staffname"), "")
}
if msg.Option(ice.MSG_USERNAME) == "" && msg.Config(tcp.LOCALHOST) == ice.TRUE && tcp.IsLocalHost(msg, msg.Option(ice.MSG_USERIP)) {
aaa.UserRoot(msg) // 本机认证
}