We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 743b049 commit c1ce189Copy full SHA for c1ce189
cloud/scope/clients.go
@@ -17,7 +17,6 @@ limitations under the License.
17
package scope
18
19
import (
20
- "crypto/tls"
21
"crypto/x509"
22
"net/http"
23
"sync"
@@ -416,9 +415,9 @@ func (c *ClientProvider) setCerts(client *http.Client) error {
416
415
if tr.TLSClientConfig != nil {
417
tr.TLSClientConfig.RootCAs = c.certOverride
418
} else {
419
- tr.TLSClientConfig = &tls.Config{
420
- RootCAs: c.certOverride,
421
- }
+ // If TLS client config is not set, we should error out. else the default values will
+ // be used which will be insecure
+ return errors.New("TLSClientConfig is not set on the client")
422
}
423
client.Transport = tr
424
0 commit comments