chore: drop unused id-token: write from auto_update_charm_libs.yaml - #1036
Open
seb4stien wants to merge 1 commit into
Open
chore: drop unused id-token: write from auto_update_charm_libs.yaml#1036seb4stien wants to merge 1 commit into
seb4stien wants to merge 1 commit into
Conversation
The job's steps (checkout, charmcraft fetch-lib, create-pull-request) authenticate via the static CHARMHUB_TOKEN secret and the GITHUB_TOKEN respectively; none of them request an OIDC token. Requiring id-token: write forces every calling workflow to grant an unused permission. Drop it from the job and update the README permissions table to match. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
Test results for commit 203e86eTest coverage for 203e86e Static code analysis report |
Contributor
Test results for commit 203e86eTest coverage for 203e86e Static code analysis report |
Contributor
Test results for commit 203e86eTest coverage for 203e86e Static code analysis report |
Contributor
Test results for commit 203e86eTest coverage for 203e86e Static code analysis report |
Contributor
Test results for commit 203e86eTest coverage for 203e86e Static code analysis report |
Contributor
Test results for commit 203e86eTest coverage for 203e86e Static code analysis report |
srbouffard
approved these changes
Aug 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
auto_update_charm_libs.yaml's job currently requestsid-token: write, forcing every calling workflow to grant an OIDC token permission it doesn't need.Looking at the job's steps:
actions/checkout— no OIDC use.charmcraft fetch-lib— authenticates to Charmhub via the staticCHARMHUB_TOKENsecret (CHARMCRAFT_AUTHenv var), not OIDC.canonical/create-pull-request— authenticates viasecrets.GITHUB_TOKEN, not OIDC.Neither
charmcraft/craft-storenorcreate-pull-requestrequest an OIDC token anywhere in their source. The `# Enable OIDC" comment and the README's permissions table appear to be leftover/aspirational rather than something actually wired up today.Change
id-token: writefrom theupdate-libjob permissions.contents: write,pull-requests: write) and clarify Charmhub auth is viaCHARMHUB_TOKEN.Follow-up for consumers
Repos calling this workflow (e.g.
canonical/nginx-ingress-integrator-operator) can dropid-token: writefrom their ownpermissions:block once this merges.If OIDC-based Charmhub trusted publishing is actually planned, happy to instead gate
id-token: writebehind an opt-in input rather than requiring it unconditionally — let me know.