mirror of
https://github.com/XrayR-project/XrayR.git
synced 2025-07-28 16:48:33 +00:00
update: reformat newV2board serverConfig structure
This commit is contained in:
@@ -171,13 +171,13 @@ func (c *Controller) checkShadowsocksPassword(password string, method string) (s
|
||||
if strings.Contains(c.panelType, "V2board") {
|
||||
var userKey string
|
||||
if len(password) < 16 {
|
||||
return "", fmt.Errorf("shadowsocks2022 key's length must be greater than 16")
|
||||
return "", newError("shadowsocks2022 key's length must be greater than 16").AtWarning()
|
||||
}
|
||||
if method == "2022-blake3-aes-128-gcm" {
|
||||
userKey = password[:16]
|
||||
} else {
|
||||
if len(password) < 32 {
|
||||
return "", fmt.Errorf("shadowsocks2022 key's length must be greater than 32")
|
||||
return "", newError("shadowsocks2022 key's length must be greater than 32").AtWarning()
|
||||
}
|
||||
userKey = password[:32]
|
||||
}
|
||||
|
Reference in New Issue
Block a user