Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/559-go-yara-bump.changed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- YARA: the engine is go-yara v0.11.1 (was v0.10.0), and the status reports `engine_version` `0.11.1` (#559).
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ go 1.27.0
toolchain go1.27.4

require (
github.com/cawalch/go-yara v0.10.0
github.com/cawalch/go-yara v0.11.1

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Stale YARA version pin blocks CI

The upgrade leaves pinnedVersion at v0.10.0, so TestPinnedVersionMatchesGoMod fails CI. Builds without dependency metadata also keep using the old YARA version in their scan cache keys.

Learn more

SentinelGo keeps a fallback YARA version for builds that do not expose the dependency in EngineVersion. The required test suite runs TestPinnedVersionMatchesGoMod, which compares that fallback with the module requirement. rulesKey also uses the resolved version to distinguish scan results produced by different engine versions.

Example: The module requires v0.11.1, but the test reads v0.10.0 from the fallback and fails. In a build without dependency metadata, the same mismatch leaves the YARA cache key unchanged when the rulesets are unchanged.

Recommended fix: Update pinnedVersion to v0.11.1 in the same PR and run go test ./internal/yara/engine.

Devin Review


Was this helpful? React with 👍 or 👎 to provide feedback.

github.com/ebitengine/purego v0.11.3
github.com/hoophq/alcatraz v0.23.0
github.com/rrethy/ahocorasick v1.0.0
Expand All @@ -16,7 +16,7 @@ require (
)

require (
github.com/cawalch/go-pe v0.0.0-20261115152824-c75b66411b12 // indirect
github.com/cawalch/go-pe v0.1.0 // indirect
github.com/dustin/go-humanize v1.1.0 // indirect
github.com/go-ole/go-ole v1.2.6 // indirect
github.com/google/uuid v1.6.0 // indirect
Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
github.com/cawalch/go-pe v0.0.0-20261115152824-c75b66411b12 h1:o6g0uRmigkzPkl0dABhAWeEq+ASKhPELbPbnAgh+R38=
github.com/cawalch/go-pe v0.0.0-20261115152824-c75b66411b12/go.mod h1:EoVGEYn1l0W480qiRMsr++ZaaqHabaHBEeMwu1BH3MU=
github.com/cawalch/go-yara v0.10.0 h1:FpX4wc9G9z7A8xzwLyNDCbQFMEo6ujUblsvvsWxjnKo=
github.com/cawalch/go-yara v0.10.0/go.mod h1:2/YOBtkPACGoVPCYaGpUzCI22yOL5dB1VK8l9sa1UIk=
github.com/cawalch/go-pe v0.1.0 h1:VyUzry7zsTR6zoK20r9NIW8ySrwsb8q/WTLFmvcs3E0=
github.com/cawalch/go-pe v0.1.0/go.mod h1:EoVGEYn1l0W480qiRMsr++ZaaqHabaHBEeMwu1BH3MU=
github.com/cawalch/go-yara v0.11.1 h1:Tr3ucuV6hHot3XOBaAfJ2C6ob1K7Bu00sC/RF2mjWTc=
github.com/cawalch/go-yara v0.11.1/go.mod h1:c0J2GV82Go3md2hrA+J3Uk5pjCXK6FkN/17ODGqE0xE=
github.com/dustin/go-humanize v1.1.0 h1:dbKTrvD0klcbBV/h4AWJdMuZogJACoMlvWIWZ5b2xWg=
github.com/dustin/go-humanize v1.1.0/go.mod h1:hc1CvRkJMsgxqjmjMQF3QNRAZBwY8AXBAzKYoSX9sFI=
github.com/ebitengine/purego v0.11.3 h1:OB+JLpdm7ioymhyA+6s5kbb/uOuYycAgL8NNTFc5MLg=
Expand Down
2 changes: 1 addition & 1 deletion internal/yara/engine/engine.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ import (
// information (TestPinnedVersionMatchesGoMod keeps the two in step).
const (
goYaraModule = "github.com/cawalch/go-yara"
pinnedVersion = "v0.10.0"
pinnedVersion = "v0.11.1"
)

// Name is the engine name the bundle's engine.name refers to.
Expand Down
Loading