EternallyAscend / GoToolkits

Use of net/http's ListenAndServe function has no support for setting timeouts GO-S2114
Security
Major
2 years ago2 years old
Use of net/http serve function that has no support for setting timeouts
38}
39
40func MuxListen(path string, port int, mux *http.ServeMux) error {
41	return http.ListenAndServe(path+":"+strconv.Itoa(port), mux)42}
43
44func MuxListenTLS(path string, port int, cert string, key string, mux *http.ServeMux) error {
Use of net/http serve function that has no support for setting timeouts
42}
43
44func MuxListenTLS(path string, port int, cert string, key string, mux *http.ServeMux) error {
45	return http.ListenAndServeTLS(path+":"+strconv.Itoa(port), cert, key, mux)46}