ci: pin actions & limit token permissions #133
Merged
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.
Motivation
Following the
tj-actions/changed-files
supply chain attack (tj-actions/changed-files#2463), figured I should harden some of my small repos tooSummary
Details
permissions: contents: read
to limit GHA token permission to least privilegeactions/checkout
,actions/setup-node
, andcodecov/codecov-action
to SHAsCredit
With some automated help from Step Security: step-security-bot@579bdc4
Prior Art
Similar to my prior work in ryanrudolfoba/SteamOS-Waydroid-Installer#224, argoproj/argo-workflows#12031, argoproj/argo-workflows#12035, argoproj/argo-workflows#12619, etc
Future Work
falco-actions
etc for anomaly detectionharden-runner
, although it doesn't have proactive egress blocking via an allowlist asharden-runner
does 😕