-
-
Notifications
You must be signed in to change notification settings - Fork 0
fix(ci): lock reusable workflow dependencies #381
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
Merged
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
48c437a
fix(ci): lock reusable workflow dependencies
hyperpolymath 0f21e30
fix(ci): complete reusable transitive lock graph
hyperpolymath 1bce511
fix(ci): repin reusable workflows to verified standard
hyperpolymath 3d69f05
style(ci): group summary output
hyperpolymath File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔒 Security & Privacy | 🟡 Minor | ⚡ Quick win
🔎 Supported by static analysis
🏁 Script executed:
Repository: hyperpolymath/ephapax
Length of output: 2316
🏁 Script executed:
Repository: hyperpolymath/ephapax
Length of output: 365
🏁 Script executed:
Repository: hyperpolymath/ephapax
Length of output: 50377
🏁 Script executed:
Repository: hyperpolymath/ephapax
Length of output: 4775
🌐 Web query:
GitHub Actions reusable workflows secrets inherit named secrets workflow_call cross repository official documentation💡 Result:
By default, GitHub Actions reusable workflows do not automatically inherit secrets from the caller workflow [1][2]. To provide secrets to a reusable workflow, you must explicitly pass them using one of two methods in the calling workflow [3][1][4]: 1. Inherit all secrets: Use the
secrets: inheritkeyword [5][4]. 2. Pass named secrets: Map specific secrets individually [3][4]. Inheriting Secrets Usingsecrets: inheritallows the reusable workflow to access all secrets available to the caller workflow (at the repository, environment, and organization levels) [3][5]. When using this approach, the reusable workflow does not need to explicitly declare the secrets in itson.workflow_call.secretsconfiguration to reference them, though doing so is still recommended for clarity and contract enforcement [3][6][7]. Passing Named Secrets Alternatively, you can pass specific secrets by name [3][4]. When doing this: - The calling workflow maps the secrets:yaml jobs: call-reusable: uses: owner/repo/.github/workflows/reusable.yml@main secrets: MY_SECRET: ${{ secrets.MY_SECRET }}- The reusable workflow must declare the expected secrets in itson.workflow_callsection to accept them [4][6][8]:yaml on: workflow_call: secrets: MY_SECRET: required: trueImportant Considerations - Scoping: Secrets are only passed to the directly called workflow [3][7]. In a chain of workflows (A > B > C), workflow A's secrets are only available to C if they are explicitly passed from A to B, and then from B to C [3][7]. - Security:secrets: inheritis a broad permission [9]. It is best used for trusted workflows within the same organization or enterprise [3][9]. For external or untrusted workflows, prefer named mapping to follow the principle of least privilege [4][9]. - Cross-Repository Access: If the reusable workflow is in a private repository, you must ensure the repository's Actions settings are configured to allow access from the caller's repository [10][11][12]. - GITHUB_TOKEN: The called workflow is automatically granted its ownGITHUB_TOKEN[10][12]. The permissions of this token can be downgraded, but not elevated, by the calling workflow [10].Citations:
Restrict secret inheritance in
.github/workflows/mirror.yml. The pinnedmirror-reusable.ymlreads seven named secrets only and has no nested workflow call.secrets: inheritcan expose every secret available to the caller. Declare the seven secrets inworkflow_calland map them explicitly. Thesecret-scanner.ymlcaller does not require this change because its pinned workflow has no executablesecrets.*reference.📍 Affects 2 files
.github/workflows/mirror.yml#L17-L17(this comment).github/workflows/secret-scanner.yml#L25-L25🤖 Prompt for AI Agents
Source: Linters/SAST tools