Merge branch 'v1.7.2' into master

This commit is contained in:
Fernandez Ludovic
2018-10-05 12:43:17 +02:00
36 changed files with 696 additions and 176 deletions

View File

@@ -530,7 +530,9 @@ func (clientTLS *ClientTLS) CreateTLSConfig() (*tls.Config, error) {
} else {
ca = []byte(clientTLS.CA)
}
caPool.AppendCertsFromPEM(ca)
if !caPool.AppendCertsFromPEM(ca) {
return nil, fmt.Errorf("failed to parse CA")
}
if clientTLS.CAOptional {
clientAuth = tls.VerifyClientCertIfGiven
} else {