mirror of
https://github.com/netbirdio/netbird.git
synced 2025-01-22 05:49:12 +01:00
Decrease the max size of the handshake message
This commit is contained in:
parent
d3e7e6bc9c
commit
1d233a5b5e
@ -249,7 +249,7 @@ func (c *Client) handShake() error {
|
||||
log.Errorf("failed to send auth message: %s", err)
|
||||
return err
|
||||
}
|
||||
buf := make([]byte, messages.MaxHandshakeSize)
|
||||
buf := make([]byte, messages.MaxHandshakeRespSize)
|
||||
n, err := c.readWithTimeout(buf)
|
||||
if err != nil {
|
||||
log.Errorf("failed to read auth response: %s", err)
|
||||
|
@ -7,7 +7,8 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
MaxHandshakeSize = 8192
|
||||
MaxHandshakeSize = 212
|
||||
MaxHandshakeRespSize = 8192
|
||||
|
||||
CurrentProtocolVersion = 1
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user