INNER CODE UNIT · Go
validateChallengesEnabled
OWASP/wrongsecrets · aws/wrongsecrets_aws_test.go:101
func validateChallengesEnabled(statusCode int, body string) bool {
// body should not contain class="disabled"
if strings.Contains(body, "class=\"disabled\"") {
log.Printf("Found class=\"disabled\" in response body")
return false
}
return statusCode == 200
}
func execute(script string, command []string) (bool, error) {
cmd := &exec.Cmd{
Path: script,
Args: command,
Stdout: os.Stdout,
Stderr: os.Stderr,
}