Skip to content
This repository has been archived by the owner on Jul 11, 2023. It is now read-only.

Commit

Permalink
utils/mtls: annotate false positive gosec warning
Browse files Browse the repository at this point in the history
The warning from gosec is a false positive because of the
usage of the InsecureSkipVerify flag, which is only set to
false for tests.
  • Loading branch information
shashankram committed Oct 15, 2020
1 parent 58aa840 commit 5d71da6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/utils/mtls.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ func setupMutualTLS(insecure bool, serverName string, certPem []byte, keyPem []b
return nil, errors.Errorf("[grpc][mTLS][%s] Failed to append client certs", serverName)
}

// #nosec G402
tlsConfig := tls.Config{
InsecureSkipVerify: insecure,
ServerName: serverName,
Expand Down

0 comments on commit 5d71da6

Please sign in to comment.