Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refresh rules at runtime for Yara Analyser Job #1550

Merged
merged 11 commits into from
Sep 30, 2024

Conversation

hacktobeer
Copy link
Collaborator

@hacktobeer hacktobeer commented Sep 20, 2024

Description of the change

Refresh the rules at runtime for the Yara Analyser Job. As we the inital ruleset is build into the worker image they will (without this PR) only be updated when a new worker iamge is build. This PR updates the rules when the Yara Analysis Job is executed.

Applicable issues

None

Additional information

This PR also:

  • sets the platform to linux/amd64 for worker, server and api-server images. We do not support other architectures (because dependencies will not work on eg aarch64.
  • git clones/pulls the ruleset at depth=1 instead of the whole repo

Checklist

  • All tests were successful.
  • Unit tests added.
  • Documentation updated.

@hacktobeer hacktobeer marked this pull request as ready for review September 20, 2024 15:41
Copy link
Collaborator

@jleaniz jleaniz left a comment

Choose a reason for hiding this comment

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

LGTM, just one comment on possible rate limit issues from Git

turbinia/workers/analysis/yara.py Outdated Show resolved Hide resolved
Copy link
Member

@aarontp aarontp left a comment

Choose a reason for hiding this comment

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

LGTM, just one minor comment about the exception that's being caught.

Regarding rate limits, hopefully it won't cause any issues if we do run into this since we will fail open in that case.

turbinia/workers/analysis/yara.py Show resolved Hide resolved
@hacktobeer hacktobeer marked this pull request as draft September 21, 2024 05:18
@hacktobeer hacktobeer marked this pull request as ready for review September 21, 2024 05:59
@hacktobeer hacktobeer merged commit c16f355 into google:master Sep 30, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants