Skip to content

Conversation

@jmgilman
Copy link
Contributor

Summary

Fix the SLSA policy branch format - the slsa.WithWorkflowBranches function automatically adds the refs/heads/ prefix, so the policy should specify just master not refs/heads/master.

Problem

The workflow on master failed with:

slsa: ref mismatch: "refs/heads/master" does not match allowed patterns

This happened because the policy had branch: refs/heads/master, which after the automatic prefix becomes ^refs/heads/refs/heads/master$.

Solution

Change branch: refs/heads/master to branch: master.

🤖 Generated with Claude Code

The slsa.WithWorkflowBranches function automatically adds the
refs/heads/ prefix, so the policy should specify just "master"
not "refs/heads/master".

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@jmgilman jmgilman merged commit 78d6aac into master Jan 24, 2026
7 checks passed
@jmgilman jmgilman deleted the fix/policy-branch-format branch January 24, 2026 06:02
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.

2 participants