mirror of
https://github.com/v2fly/v2ray-core.git
synced 2025-12-28 13:05:28 -05:00
comments
This commit is contained in:
@@ -30,6 +30,7 @@ func hashTimestamp(t protocol.Timestamp) []byte {
|
||||
return bytes
|
||||
}
|
||||
|
||||
// ClientSession stores connection session info for VMess client.
|
||||
type ClientSession struct {
|
||||
requestBodyKey []byte
|
||||
requestBodyIV []byte
|
||||
@@ -40,6 +41,7 @@ type ClientSession struct {
|
||||
idHash protocol.IDHash
|
||||
}
|
||||
|
||||
// NewClientSession creates a new ClientSession.
|
||||
func NewClientSession(idHash protocol.IDHash) *ClientSession {
|
||||
randomBytes := make([]byte, 33) // 16 + 16 + 1
|
||||
rand.Read(randomBytes)
|
||||
|
||||
Reference in New Issue
Block a user