linter fixes.
This commit is contained in:
@@ -39,7 +39,7 @@ func main() {
|
||||
|
||||
revoke.HardFail = hardfail
|
||||
// Build a proxy-aware HTTP client for OCSP/CRL fetches
|
||||
if httpClient, err := dialer.NewHTTPClient(dialer.DialerOpts{Timeout: timeout}); err == nil {
|
||||
if httpClient, err := dialer.NewHTTPClient(dialer.Opts{Timeout: timeout}); err == nil {
|
||||
revoke.HTTPClient = httpClient
|
||||
}
|
||||
|
||||
@@ -105,7 +105,7 @@ func checkSite(hostport string) (string, error) {
|
||||
defer cancel()
|
||||
|
||||
// Use proxy-aware TLS dialer
|
||||
conn, err := dialer.DialTLS(ctx, target.String(), dialer.DialerOpts{Timeout: timeout, TLSConfig: &tls.Config{
|
||||
conn, err := dialer.DialTLS(ctx, target.String(), dialer.Opts{Timeout: timeout, TLSConfig: &tls.Config{
|
||||
InsecureSkipVerify: true, // #nosec G402 -- CLI tool only verifies revocation
|
||||
ServerName: target.Host,
|
||||
}})
|
||||
|
||||
@@ -25,7 +25,11 @@ func main() {
|
||||
}
|
||||
|
||||
// Use proxy-aware TLS dialer
|
||||
conn, err := dialer.DialTLS(context.Background(), server, dialer.DialerOpts{TLSConfig: &tls.Config{}}) // #nosec G402
|
||||
conn, err := dialer.DialTLS(
|
||||
context.Background(),
|
||||
server,
|
||||
dialer.Opts{TLSConfig: &tls.Config{}},
|
||||
) // #nosec G402
|
||||
die.If(err)
|
||||
|
||||
defer conn.Close()
|
||||
|
||||
@@ -85,7 +85,7 @@ func main() {
|
||||
continue
|
||||
}
|
||||
// Use proxy-aware HTTP client with a reasonable timeout for connects/handshakes
|
||||
httpClient, err := dialer.NewHTTPClient(dialer.DialerOpts{Timeout: 30 * time.Second})
|
||||
httpClient, err := dialer.NewHTTPClient(dialer.Opts{Timeout: 30 * time.Second})
|
||||
if err != nil {
|
||||
_, _ = lib.Warn(err, "building HTTP client for %s", remote)
|
||||
continue
|
||||
|
||||
@@ -43,7 +43,7 @@ func main() {
|
||||
}
|
||||
|
||||
var conn *tls.Conn
|
||||
conn, err = dialer.DialTLS(context.Background(), site, dialer.DialerOpts{TLSConfig: tlsCfg})
|
||||
conn, err = dialer.DialTLS(context.Background(), site, dialer.Opts{TLSConfig: tlsCfg})
|
||||
die.If(err)
|
||||
|
||||
cs := conn.ConnectionState()
|
||||
|
||||
@@ -25,7 +25,7 @@ func main() {
|
||||
conn, err := dialer.DialTLS(
|
||||
context.Background(),
|
||||
hostPort.String(),
|
||||
dialer.DialerOpts{TLSConfig: &tls.Config{InsecureSkipVerify: true}},
|
||||
dialer.Opts{TLSConfig: &tls.Config{InsecureSkipVerify: true}},
|
||||
) // #nosec G402
|
||||
die.If(err)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user