Commit 04936958 authored by Miek Gieben's avatar Miek Gieben Committed by GitHub

pkg/tls: remove InsecureSkipVerify=true flag (#4265)

CWE-295 code scanning alert flag this. Seems OK to just remove it.
Signed-off-by: default avatarMiek Gieben <miek@miek.nl>
parent 723e9b06
...@@ -108,11 +108,6 @@ func loadRoots(caPath string) (*x509.CertPool, error) { ...@@ -108,11 +108,6 @@ func loadRoots(caPath string) (*x509.CertPool, error) {
// NewHTTPSTransport returns an HTTP transport configured using tls.Config // NewHTTPSTransport returns an HTTP transport configured using tls.Config
func NewHTTPSTransport(cc *tls.Config) *http.Transport { func NewHTTPSTransport(cc *tls.Config) *http.Transport {
// this seems like a bad idea but was here in the previous version
if cc != nil {
cc.InsecureSkipVerify = true
}
tr := &http.Transport{ tr := &http.Transport{
Proxy: http.ProxyFromEnvironment, Proxy: http.ProxyFromEnvironment,
Dial: (&net.Dialer{ Dial: (&net.Dialer{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment