From 1f06f242cc18ca99cc9f69164341592139f85d64 Mon Sep 17 00:00:00 2001 From: Manuel Sabban Date: Wed, 14 Sep 2022 15:26:26 +0200 Subject: [PATCH] fix https://github.com/crowdsecurity/crowdsec/issues/1746 (#1749) Co-authored-by: sabban <15465465+sabban@users.noreply.github.com> --- pkg/parser/unix_parser.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkg/parser/unix_parser.go b/pkg/parser/unix_parser.go index 0d9ee7d82..670776956 100644 --- a/pkg/parser/unix_parser.go +++ b/pkg/parser/unix_parser.go @@ -4,6 +4,7 @@ import ( "fmt" "os" "path" + "strings" "github.com/crowdsecurity/crowdsec/pkg/csconfig" @@ -37,6 +38,9 @@ func Init(c map[string]interface{}) (*UnixParserCtx, error) { } r.DataFolder = c["data"].(string) for _, f := range files { + if strings.Contains(f.Name(), ".") { + continue + } if err := r.Grok.AddFromFile(path.Join(c["patterns"].(string), f.Name())); err != nil { log.Errorf("failed to load pattern %s : %v", f.Name(), err) return nil, err