From 18b2d6d2a59e2636700399169a5eb687b567745d Mon Sep 17 00:00:00 2001 From: Andrew Ayer Date: Tue, 30 Jun 2020 10:37:34 -0400 Subject: [PATCH] Add support for contacting logs via HTTP proxies Just set the appropriate environment variable as documented at https://golang.org/pkg/net/http/#ProxyFromEnvironment Closes: #31 Closes: #41 --- ct/client/logclient.go | 1 + 1 file changed, 1 insertion(+) diff --git a/ct/client/logclient.go b/ct/client/logclient.go index 209d680..e5adc09 100644 --- a/ct/client/logclient.go +++ b/ct/client/logclient.go @@ -90,6 +90,7 @@ func New(uri string) *LogClient { var c LogClient c.uri = uri transport := &httpclient.Transport{ + Proxy: http.ProxyFromEnvironment, ConnectTimeout: 10 * time.Second, RequestTimeout: 60 * time.Second, ResponseHeaderTimeout: 30 * time.Second,