diff --git a/cmd/server/main.go b/cmd/server/main.go index 87334e8..3ddca3f 100644 --- a/cmd/server/main.go +++ b/cmd/server/main.go @@ -44,6 +44,12 @@ func main() { DisableStartupMessage: true, ReadTimeout: 10 * time.Second, WriteTimeout: 10 * time.Second, + // fasthttp defaults to a 4 KB read buffer per connection; + // any request whose header line exceeds that returns a flat + // HTTP 431 before any handler runs. 16 KB matches the + // cluster's nginx-ingress large_client_header buffer and + // accommodates chunked NextAuth cookies + large bearer tokens. + ReadBufferSize: 16384, }) app.Use(recover.New()) app.Use(logger.New(logger.Config{