fix security issues

This commit is contained in:
2025-03-16 13:47:40 +02:00
parent 7603f9395a
commit 837c5863fd
2 changed files with 10 additions and 3 deletions

View File

@@ -7,6 +7,7 @@ import (
"log"
"net/http"
"os"
"time"
"github.com/go-chi/chi"
"github.com/go-chi/cors"
@@ -89,8 +90,9 @@ func main() {
router.Mount("/v1", v1Router)
srv := &http.Server{
Addr: ":" + port,
Handler: router,
Addr: ":" + port,
Handler: router,
ReadHeaderTimeout: time.Second * 30,
}
log.Printf("Serving on port: %s\n", port)