mirror of
https://github.com/tailscale/tailscale.git
synced 2025-10-09 08:01:31 +00:00
derp, cmd/derper: add rate limiting support, add default 5Mbps limit
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:

committed by
Dave Anderson

parent
1166c34f6c
commit
88f1cc0c98
@@ -131,7 +131,7 @@ func (c *Client) send(dstKey key.Public, pkt []byte) (ret error) {
|
||||
}
|
||||
}()
|
||||
|
||||
if len(pkt) > 64<<10 {
|
||||
if len(pkt) > maxPacketData {
|
||||
return fmt.Errorf("packet too big: %d", len(pkt))
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user