golangci-lint/test/testdata/gosec_global_option.go
hbc 52edd01248
gosec: convert global settings as map with proper key type (#3779)
Co-authored-by: Fernandez Ludovic <ldez@users.noreply.github.com>
2023-04-21 22:20:59 +02:00

15 lines
338 B
Go

//golangcitest:args -Egosec
//golangcitest:config_path testdata/configs/gosec_global_option.yml
package testdata
import (
"crypto/md5" // want "G501: Blocklisted import crypto/md5: weak cryptographic primitive"
"log"
)
func Gosec() {
// #nosec G401
h := md5.New() // want "G401: Use of weak cryptographic primitive"
log.Print(h)
}