Files
netbird/upload-server
riccardom 7e2b71d7f8 [misc] Bound the upload server's request timeouts
http.Server was built with only Addr and Handler, so every timeout was infinite.
Behind a reverse proxy that is survivable because the proxy has its own; serving
TLS directly, which SERVER_CERT_FILE now allows, it means a slow client can hold
a connection and its goroutine indefinitely.

ReadHeaderTimeout and IdleTimeout are short. ReadTimeout is 10 minutes: it has
to clear a 150 MiB upload on a slow link, so it is a ceiling on a stalled
connection rather than a throughput rule. WriteTimeout is deliberately left
unset for the same reason.

Reported by CodeRabbit (CWE-400) on #7514.
2026-09-14 09:20:03 +02:00
..