Skip to content

Commit

Permalink
util: use tls1.0 as min tls version (pingcap#35011) (pingcap#36620)
Browse files Browse the repository at this point in the history
  • Loading branch information
ti-srebot authored Jul 27, 2022
1 parent 6e9fd42 commit 099c736
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions util/security.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,9 @@ func ToTLSConfigWithVerify(caPath, certPath, keyPath string, verifyCN []string)
if !certPool.AppendCertsFromPEM(ca) {
return nil, errors.New("failed to append ca certs")
}

/* #nosec G402 */
tlsCfg := &tls.Config{
MinVersion: tls.VersionTLS12,
MinVersion: tls.VersionTLS10,
Certificates: certificates,
RootCAs: certPool,
ClientCAs: certPool,
Expand Down Expand Up @@ -125,9 +125,9 @@ func ToTLSConfigWithVerifyByRawbytes(caData, certData, keyData []byte, verifyCN
if !certPool.AppendCertsFromPEM(caData) {
return nil, errors.New("failed to append ca certs")
}

/* #nosec G402 */
tlsCfg := &tls.Config{
MinVersion: tls.VersionTLS12,
MinVersion: tls.VersionTLS10,
Certificates: certificates,
RootCAs: certPool,
ClientCAs: certPool,
Expand Down

0 comments on commit 099c736

Please sign in to comment.