tailscale/cmd/derper
Joe Tsai 0173a50bf0
cmd/derper: add a rate limiter for accepting new connection (#3908)
A large influx of new connections can bring down DERP
since it spins off a new goroutine for each connection,
where each routine may do significant amount of work
(e.g., allocating memory and crunching numbers for TLS crypto).
The momentary spike can cause the process to OOM.

This commit sets the groundwork for limiting connections,
but leaves the limit at infinite by default.

Signed-off-by: Joe Tsai <joetsai@digital-static.net>
2022-02-11 12:02:38 -08:00
..
bootstrap_dns.go cmd/derper: add /bootstrap-dns handler 2021-02-26 09:29:28 -08:00
cert.go cmd/derper: in manual cert mode, don't discard error from VerifyHostname 2022-01-11 08:40:42 -08:00
derper_test.go cmd/derper: refactor STUN path for testing, add serverSTUN benchmark 2021-09-13 10:12:32 -07:00
derper.go cmd/derper: add a rate limiter for accepting new connection (#3908) 2022-02-11 12:02:38 -08:00
mesh.go derp: use new node key type. 2021-10-28 16:02:11 -07:00
websocket.go cmd/derper, derp/derphttp: add websocket support 2021-10-22 12:51:30 -07:00