mirror of
https://github.com/securego/gosec.git
synced 2025-06-14 23:45:03 +02:00
Reset the state of TLS rule after each version check (#570)
Signed-off-by: Cosmin Cojocar <ccojocar@cloudbees.com>
This commit is contained in:
@ -2057,7 +2057,24 @@ func main() {
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
}`}, 0, gosec.NewConfig()}}
|
||||
}`}, 0, gosec.NewConfig()}, {[]string{`
|
||||
package p0
|
||||
|
||||
import "crypto/tls"
|
||||
|
||||
func TlsConfig0() *tls.Config {
|
||||
var v uint16 = 0
|
||||
return &tls.Config{MinVersion: v}
|
||||
}
|
||||
`, `
|
||||
package p0
|
||||
|
||||
import "crypto/tls"
|
||||
|
||||
func TlsConfig1() *tls.Config {
|
||||
return &tls.Config{MinVersion: 0x0304}
|
||||
}
|
||||
`}, 1, gosec.NewConfig()}}
|
||||
|
||||
// SampleCodeG403 - weak key strength
|
||||
SampleCodeG403 = []CodeSample{
|
||||
|
Reference in New Issue
Block a user