测试
This commit is contained in:
@@ -626,7 +626,7 @@ func (s *Service) setupNode() error {
|
||||
ssOptions.Users = []option.ShadowsocksUser{{
|
||||
Password: base64.StdEncoding.EncodeToString(dummyKey),
|
||||
}}
|
||||
s.logger.Info("Xboard SS2022 setup. Method: ", method, " ServerKey (PSK) used directly from panel")
|
||||
s.logger.Info("Xboard SS2022 setup. Method: ", method, " ServerKey(PSK): ", serverKey)
|
||||
} else {
|
||||
// Legacy SS: password-based
|
||||
ssOptions.Password = serverKey
|
||||
@@ -892,7 +892,12 @@ func (s *Service) syncUsers() {
|
||||
// V2bX approach for SS2022 user key:
|
||||
// Take first keyLen bytes of UUID, then base64 encode
|
||||
if isSS2022 {
|
||||
originalKey := key
|
||||
key = ss2022UserKey(key, ss2022KeyLen)
|
||||
if len(newUsers) == 0 {
|
||||
// Log first user's key derivation for debugging
|
||||
s.logger.Info("SS2022 user key derivation: UUID[:", ss2022KeyLen, "]=", originalKey[:min(ss2022KeyLen, len(originalKey))], " → uPSK=", key)
|
||||
}
|
||||
}
|
||||
|
||||
newUsers[u.Email] = userData{
|
||||
|
||||
Reference in New Issue
Block a user