Skip to content

Switches from protected_branches to rulesets - #4095

Merged
ppkarwasz merged 6 commits into
2.xfrom
feat/rulesets
Sep 2, 2026
Merged

ppkarwasz merged 6 commits into
2.xfrom
feat/rulesets

Conversation

@ppkarwasz

Copy link
Copy Markdown
Member

Similarly to apache/logging-parent#456 this PR switches from GitHub Branch Protection to Rulesets and:

  • Keeps the same rules for main, while protection 2.x is temporarily disabled in case we need to update the .asf.yaml file.
  • Adds tag protection for the rel/* tags.

@ppkarwasz

Copy link
Copy Markdown
Member Author

After successfully enabling rulesets in logging-parent, I extended this PR to cover the 2.x branch in cccea50. One small catch: until apache/infrastructure-asfyaml#93 is merged, these rulesets cannot be modified.

@puerco: are these controls sufficient to classify Log4j as SLSA Source Level 4 compliant? As you know, we enforce quite a "Byzantine bureaucracy" here and would love something to show for it:

SLSA 4

...alongside the in-toto attestations we will produce.

A couple of related questions:

  • Should we also protect release/* branches to demonstrate that every commit up to a release has been reviewed? The rel/* tags sit on short-lived side branches that originate from the two protected branches (2.x and main).
  • For tags, I opened Tag cleanup and protection #4096 to discuss cleaning up some historical inconsistencies before locking down rel/* tags.

Note

For bystanders wondering: SLSA would not have prevented Log4Shell. It only protects against malicious actors, not honest mistakes that pass the full review process.

@ppkarwasz ppkarwasz moved this to Waiting for review in Log4j pull request tracker Apr 16, 2026
Similarly to apache/logging-parent#456 this PR switches from GitHub Branch Protection to Rulesets and:

- Keeps the same rules for `main`, while protection `2.x` is **temporarily** disabled in case we need to update the `.asf.yaml` file.
- Adds tag protection for the `rel/*` tags.
@ppkarwasz

Copy link
Copy Markdown
Member Author

Since 2.25.x and 2.26.x are also release branches, 8ddf8cb adds them to the protected list.

@ppkarwasz
ppkarwasz enabled auto-merge (squash) September 2, 2026 19:42

@FreeAndNil FreeAndNil left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lgtm

@github-project-automation github-project-automation Bot moved this from Waiting for review to Approved in Log4j pull request tracker Sep 2, 2026
@ppkarwasz
ppkarwasz merged commit 008f69b into 2.x Sep 2, 2026
13 checks passed
@ppkarwasz
ppkarwasz deleted the feat/rulesets branch September 2, 2026 21:48
@github-project-automation github-project-automation Bot moved this from Approved to Merged in Log4j pull request tracker Sep 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

2 participants