mirror of
https://github.com/lkddi/Xboard.git
synced 2026-04-28 06:47:24 +08:00
Merge pull request #497 from ztbh/master
Fix the bug of sub-node ss password mismatch
This commit is contained in:
@@ -276,7 +276,9 @@ class Server extends Model
|
|||||||
}
|
}
|
||||||
|
|
||||||
$config = self::CIPHER_CONFIGURATIONS[$cipher];
|
$config = self::CIPHER_CONFIGURATIONS[$cipher];
|
||||||
$serverKey = Helper::getServerKey($this->created_at, $config['serverKeySize']);
|
// Use parent's created_at if this is a child node
|
||||||
|
$serverCreatedAt = $this->parent_id ? $this->parent->created_at : $this->created_at;
|
||||||
|
$serverKey = Helper::getServerKey($serverCreatedAt, $config['serverKeySize']);
|
||||||
$userKey = Helper::uuidToBase64($user->uuid, $config['userKeySize']);
|
$userKey = Helper::uuidToBase64($user->uuid, $config['userKeySize']);
|
||||||
return "{$serverKey}:{$userKey}";
|
return "{$serverKey}:{$userKey}";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user