From b5ae3d806ad289b6a776cc3945c26c7e62f39f57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?EMRE=20=C3=87EL=C4=B0K?= Date: Sat, 25 Jun 2022 13:24:58 +0300 Subject: [PATCH] Unnecessary configs removed & Read and Write Timeouts added --- server/dashboard.go | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/server/dashboard.go b/server/dashboard.go index bfcad7c4..6a68d582 100644 --- a/server/dashboard.go +++ b/server/dashboard.go @@ -77,15 +77,6 @@ func (svr *Service) RunDashboardServer(address string) (err error) { return err } cfg := &tls.Config{ - MinVersion: tls.VersionTLS12, - CurvePreferences: []tls.CurveID{tls.CurveP521, tls.CurveP384, tls.CurveP256}, - PreferServerCipherSuites: true, - CipherSuites: []uint16{ - tls.TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384, - tls.TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, - tls.TLS_RSA_WITH_AES_256_GCM_SHA384, - tls.TLS_RSA_WITH_AES_256_CBC_SHA, - }, Certificates: []tls.Certificate{cer}, } server := &http.Server{ @@ -93,6 +84,8 @@ func (svr *Service) RunDashboardServer(address string) (err error) { Handler: router, TLSConfig: cfg, TLSNextProto: make(map[string]func(*http.Server, *tls.Conn, http.Handler), 0), + ReadTimeout: httpServerReadTimeout, + WriteTimeout: httpServerWriteTimeout, } go server.ListenAndServeTLS("", "") } else {