헤더 사이즈 늘림

This commit is contained in:
2024-08-05 16:27:54 +09:00
parent 7928e69c60
commit 38c5e05d4c

View File

@ -169,7 +169,11 @@ func NewHTTPServerWithPort(serveMux ServerMuxInterface, port int) *Server {
registUnhandledPattern(serveMux)
server := &Server{
httpserver: &http.Server{Addr: addr, Handler: serveMux},
httpserver: &http.Server{
Addr: addr,
Handler: serveMux,
MaxHeaderBytes: 2 << 20, // 2 MB
},
}
server.httpserver.SetKeepAlivesEnabled(true)