gosec/testutils/g504_samples.go
Cosmin Cojocar 2aad3f02a5 Fix lint warnings by properly formatting the files
Signed-off-by: Cosmin Cojocar <gcojocar@adobe.com>
2023-12-08 14:46:36 +01:00

19 lines
305 B
Go

package testutils
import "github.com/securego/gosec/v2"
// SampleCodeG504 - Blocklisted import CGI
var SampleCodeG504 = []CodeSample{
{[]string{`
package main
import (
"net/http/cgi"
"net/http"
)
func main() {
cgi.Serve(http.FileServer(http.Dir("/usr/share/doc")))
}
`}, 1, gosec.NewConfig()},
}