8000 chore: give back list of promoted rules by ariel-anieli · Pull Request #5420 · SigmaHQ/sigma · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

chore: give back list of promoted rules #5420

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

ariel-anieli
Copy link
Contributor
@ariel-anieli ariel-anieli commented May 15, 2025

Summary of the Pull Request

tests/promote_rules_status.py gives back no output,

# .venv/bin/python3 tests/promote_rules_status.py; echo $?
0

And does not tell which rules when promoted. Now, the rules are given back.

Moreover, the building of artifacts is added into the promotion workflow.

Changelog

chore: update tests/promote_rules_status.py to return the promoted rules
chore: .github/workflows/sigma-rule-promoter.yml to build artifacts of promoted rules

Example Log Event

Fixed Issues

SigmaHQ Rule Creation Conventions

  • If your PR adds new rules, please consider following and applying these conventions

@github-actions github-actions bot added the Maintenance Related to additions and update of the repository features label May 15, 2025
@phantinuss phantinuss changed the title tests: give back list of promoted rules chore: give back list of promoted rules May 16, 2025
@phantinuss
Copy link
Collaborator

Hi,

thanks for contributing. I am curious. Is there a specific reason for you to add this feature? We don't really use the output outside the build job like that. Maybe there is another enhancement we can make (build artefact, add it to the message in the PR, ...)

@ariel-anieli
Copy link
Contributor 8000 Author
ariel-anieli commented May 16, 2025

Hi,

thanks for contributing. I am curious. Is there a specific reason for you to add this feature? We don't really use the output outside the build job like that. Maybe there is another enhancement we can make (build artefact, add it to the message in the PR, ...)

Your welcome, @phantinuss. I am new to the project, and I was looking into the test directory. I thought it would make a better user experience.

Sure, I'd be glad to work these tasks. I will push other PRs as this one is merged.

The changes some be done in the promotion workflow; right?

@phantinuss phantinuss added the 2nd Review Needed PR need a second approval label May 23, 2025
@ariel-anieli ariel-anieli requested a review from phantinuss June 1, 2025 21:13
@ariel-anieli
Copy link
Contributor Author
ariel-anieli commented Jun 1, 2025

@phantinuss, here is the PR for review. I have added the building of artifacts in the promotion workflow.

An example of the workflow output.

@ariel-anieli ariel-anieli force-pushed the promote-ux branch 2 times, most recently from 36ac9eb to 18fc668 Compare June 8, 2025 17:18
ariel-anieli and others added 3 commits June 13, 2025 15:55
Refactor for an upcoming commit:

- promote_rule renamed from promote_rules, its input is now a rule
- is_experimental_and_older_than_ref extracted from get_rules_to_promote

Co-authored-by: phantinuss <79651203+phantinuss@users.noreply.github.com>
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
tests/promote_rules_status.py gives back no output,

> .venv/bin/python3 tests/promote_rules_status.py; echo $?
0

And does not tell which rules were promoted.

Useful for an upcoming CI/CD commit.

Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
Build artifacts of promoted rules by installing a backend, and choosing
any pipeline compatible with that backend.

The selection is random: for each CI/CD run, a different pair of
target/pipeline is tested. This will help to detect incompatibilities
between backends, targets, or rules.

GH issue: SigmaHQ#5422
Suggested-by: phantinuss <79651203+phantinuss@users.noreply.github.com>
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2nd Review Needed PR need a second approval Maintenance Related to additions and update of the repository features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0