Skip to content

Commit

Permalink
Update listener.go
Browse files Browse the repository at this point in the history
  • Loading branch information
bharath-b23 authored Feb 28, 2018
1 parent 82f1694 commit e76f498
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion command/server/listener.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,12 @@ func listenerWrapTLS(
if disableClientCerts && requireVerifyCerts {
return nil, nil, nil, fmt.Errorf("'tls_disable_client_certs' and 'tls_require_and_verify_client_cert' are mutually exclusive")
}
tlsConf.ClientAuth = tls.NoClientCert
if disableClientCerts {
tlsConf.ClientAuth = tls.NoClientCert
}
if !disableClientCerts {
tlsConf.ClientAuth = tls.VerifyClientCertIfGiven
}
}

ln = tls.NewListener(ln, tlsConf)
Expand Down

0 comments on commit e76f498

Please sign in to comment.