-
Notifications
You must be signed in to change notification settings - Fork 1
Harden GHA #90
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
+124
−11
Merged
Harden GHA #90
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,65 @@ | ||
| name: security | ||
|
|
||
| on: | ||
| pull_request: | ||
| merge_group: | ||
|
|
||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | ||
| cancel-in-progress: true | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| pinact: | ||
| name: pinact | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: read | ||
| steps: | ||
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | ||
|
cursor[bot] marked this conversation as resolved.
|
||
| with: | ||
| persist-credentials: false | ||
|
|
||
| - uses: suzuki-shunsuke/pinact-action@cf51507d80d4d6522a07348e3d58790290eaf0b6 # v2.0.0 | ||
| with: | ||
| skip_push: "true" # validate only; fail CI on unpinned actions | ||
|
|
||
| zizmor: | ||
| name: zizmor | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: read | ||
| security-events: write # upload SARIF findings to Code Scanning | ||
| actions: read # required by zizmor-action for private/internal repos | ||
| steps: | ||
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | ||
| with: | ||
| persist-credentials: false | ||
|
|
||
| - uses: zizmorcore/zizmor-action@b1d7e1fb5de872772f31590499237e7cce841e8e # v0.5.3 | ||
| with: | ||
| persona: pedantic | ||
|
|
||
| security: | ||
| name: security | ||
| permissions: {} | ||
| if: always() | ||
| needs: | ||
| - pinact | ||
| - zizmor | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Print all job results | ||
| env: | ||
| NEEDS_JSON: ${{ toJson(needs) }} | ||
| GITHUB_EVENT_NAME: ${{ github.event_name }} | ||
| run: | | ||
| echo "'needs': ${NEEDS_JSON}" | ||
| echo "github.event_name: ${GITHUB_EVENT_NAME}" | ||
|
|
||
| # In the merge queue, any skipped job is a failure (everything must run). | ||
| # In PR CI, skips are allowed (e.g. fork PRs without OIDC). | ||
| - if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') || (github.event_name == 'merge_group' && contains(needs.*.result, 'skipped')) }} | ||
| run: exit 1 | ||
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| rules: | ||
| dependabot-cooldown: | ||
| config: | ||
| days: 3 | ||
|
|
||
| # pinact owns SHA-pinning enforcement; suppress here to avoid duplicate failures. | ||
| unpinned-uses: | ||
| ignore: | ||
| - ci.yml | ||
| - benchmark.yml | ||
|
|
||
| # dtolnay/rust-toolchain is preferred over plain rustup for its caching and | ||
| # parallel component install behaviour — keeping it is an explicit choice. | ||
| superfluous-actions: | ||
| ignore: | ||
| - ci.yml | ||
| - benchmark.yml | ||
|
|
||
| # dtolnay/rust-toolchain publishes only via `master`; no tags exist to pin to, | ||
| # so a SHA pointing at master is the best available reference. | ||
| stale-action-refs: | ||
| ignore: | ||
| - ci.yml | ||
| - benchmark.yml | ||
|
|
||
| # The Postgres service container is for ephemeral test/bench use only; pinning | ||
| # to a SHA256 digest would add maintenance churn with no security benefit. | ||
| unpinned-images: | ||
| ignore: | ||
| - benchmark.yml |
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.
Uh oh!
There was an error while loading. Please reload this page.