BindsToAllNetworkInterfaces should check TLS also

This commit is contained in:
mockturtl 2017-03-28 13:24:22 -04:00
parent 177fa7dde0
commit b74c83e7e7

View file

@ -41,7 +41,7 @@ func (r *BindsToAllNetworkInterfaces) Match(n ast.Node, c *gas.Context) (gi *gas
func NewBindsToAllNetworkInterfaces(conf map[string]interface{}) (gas.Rule, []ast.Node) { func NewBindsToAllNetworkInterfaces(conf map[string]interface{}) (gas.Rule, []ast.Node) {
return &BindsToAllNetworkInterfaces{ return &BindsToAllNetworkInterfaces{
call: regexp.MustCompile(`^net\.Listen$`), call: regexp.MustCompile(`^(net|tls)\.Listen$`),
pattern: regexp.MustCompile(`^(0.0.0.0|:).*$`), pattern: regexp.MustCompile(`^(0.0.0.0|:).*$`),
MetaData: gas.MetaData{ MetaData: gas.MetaData{
Severity: gas.Medium, Severity: gas.Medium,