Composite rules (#1905)

* composite rules

* add test config

* tests

* taking care of some pr comments

* naming
This commit is contained in:
Zachary Rice authored and GitHub committed 2025-07-20 11:13:38 -05:00
1 parent 72977e41b6
commit b1c9c7ecbe
9 files changed
+473 -21

No files matched your search

+5
View File
@@ -232,7 +232,9 @@ func printFinding(f report.Finding, noColor bool) {
fmt.Printf("%-12s %s\n", "RuleID:", f.RuleID)
fmt.Printf("%-12s %f\n", "Entropy:", f.Entropy)
if f.File == "" {
f.PrintRequiredFindings()
fmt.Println("")
return
}
@@ -243,6 +245,7 @@ func printFinding(f report.Finding, noColor bool) {
fmt.Printf("%-12s %d\n", "Line:", f.StartLine)
if f.Commit == "" {
fmt.Printf("%-12s %s\n", "Fingerprint:", f.Fingerprint)
f.PrintRequiredFindings()
fmt.Println("")
return
}
@@ -254,5 +257,7 @@ func printFinding(f report.Finding, noColor bool) {
if f.Link != "" {
fmt.Printf("%-12s %s\n", "Link:", f.Link)
}
f.PrintRequiredFindings()
fmt.Println("")
}