-
-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: detects well-known publisher actions in cache-audit (#338)
- Loading branch information
1 parent
82bbdb4
commit e6b1699
Showing
4 changed files
with
159 additions
and
27 deletions.
There are no files selected for viewing
This file contains 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 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 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,19 @@ | ||
--- | ||
source: tests/snapshot.rs | ||
expression: "zizmor().workflow(workflow_under_test(\"cache-poisoning/publisher-step.yml\")).run()?" | ||
snapshot_kind: text | ||
--- | ||
error[cache-poisoning]: runtime artifacts potentially vulnerable to a cache poisoning attack | ||
--> @@INPUT@@:23:9 | ||
| | ||
16 | uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab | ||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ cache enabled by default here | ||
17 | | ||
... | ||
22 | - name: Publish draft release on Github | ||
23 | uses: softprops/action-gh-release@01570a1f39cb168c169c802c3bceb9e93fb10974 | ||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ runtime artifacts usually published here | ||
| | ||
= note: audit confidence → Low | ||
|
||
1 finding: 0 unknown, 0 informational, 0 low, 0 medium, 1 high |
This file contains 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,32 @@ | ||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
publish: | ||
runs-on: macos-latest | ||
steps: | ||
- name: Project Checkout | ||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 | ||
with: | ||
persist-credentials: false | ||
|
||
- name: Setup CI caching | ||
uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab | ||
|
||
- name: Build snapshot version of artifacts | ||
id: build | ||
run: cargo xtasks darwin-build | ||
|
||
- name: Publish draft release on Github | ||
uses: softprops/action-gh-release@01570a1f39cb168c169c802c3bceb9e93fb10974 | ||
with: | ||
name: ${{ steps.build.outputs.version }} | ||
tag_name: ${{ steps.build.outputs.version }} | ||
token: ${{ secrets.GITHUB_RELEASES_TOKEN }} | ||
generate_release_notes: false | ||
draft: false | ||
files: | | ||
target/aarch64-apple-darwin/release/my-app | ||
target/x86_64-apple-darwin/release/my-app |