mirror of
https://github.com/ehang-io/nps.git
synced 2026-11-01 01:02:12 +08:00
new feature multi user auth with socks5
This commit is contained in:
1 parent
5e55b761cf
commit
a05995fba5
4 files changed
+15
-12
No files matched your search
@@ -240,15 +240,14 @@ func dealTunnel(s string) *file.Tunnel {
|
||||
case "strip_pre":
|
||||
t.StripPre = item[1]
|
||||
case "multi_user":
|
||||
// TODO add test with multi user config file
|
||||
t.Client.Cnf.MultiUser = true
|
||||
t.MultiUser = new(file.MultiUser)
|
||||
if b, err := common.ReadAllFromFile(item[1]); err != nil {
|
||||
panic(err)
|
||||
} else {
|
||||
if content, err := common.ParseStr(string(b)); err != nil {
|
||||
panic(err)
|
||||
} else {
|
||||
t.Client.Cnf.MultiUserMap = dealMultiUser(content)
|
||||
t.MultiUser.UserMap = dealMultiUser(content)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user