Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .github/workflows/deny.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Deny

on:
push:
branches: [main]
paths: [Cargo.lock, deny.toml]
pull_request:
paths: [Cargo.lock, deny.toml]

permissions:
contents: read

jobs:
deny:
name: cargo-deny
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Run cargo-deny
uses: EmbarkStudios/cargo-deny-action@v2
Comment on lines +19 to +22
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify all workflow actions are SHA-pinned (40 hex chars)
rg -n 'uses:\s*[^@]+@([0-9a-f]{40})$' .github/workflows/deny.yml
rg -n 'uses:\s*[^@]+@' .github/workflows/deny.yml
# Expected: every `uses:` line should appear in the first command's output.

Repository: morph-l2/morph-reth

Length of output: 151


Pin GitHub Actions to immutable commit SHAs.

Lines 19 and 22 pin actions to mutable tags (@v4, @v2). This weakens supply-chain security; pin to full 40-character commit SHAs instead.

Suggested patch
        uses: actions/checkout@v4
+        uses: actions/checkout@<full_commit_sha>

      - name: Run cargo-deny
-        uses: EmbarkStudios/cargo-deny-action@v2
+        uses: EmbarkStudios/cargo-deny-action@<full_commit_sha>
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/deny.yml around lines 19 - 22, The workflow uses mutable
tags "actions/checkout@v4" and "EmbarkStudios/cargo-deny-action@v2"; replace
those tag references with the corresponding full 40-character commit SHAs (e.g.,
actions/checkout@<full_sha> and EmbarkStudios/cargo-deny-action@<full_sha>) so
the runner pins to immutable commits—update the uses entries for
actions/checkout and EmbarkStudios/cargo-deny-action accordingly and verify the
SHAs match the intended release commits.

with:
command: check all
50 changes: 25 additions & 25 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

83 changes: 83 additions & 0 deletions deny.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# This section is considered when running `cargo deny check advisories`
# More documentation for the advisories section can be found here:
# https://embarkstudios.github.io/cargo-deny/checks/advisories/cfg.html
[advisories]
yanked = "warn"
ignore = [
# https://rustsec.org/advisories/RUSTSEC-2024-0436 paste! is unmaintained
"RUSTSEC-2024-0436",
# https://rustsec.org/advisories/RUSTSEC-2025-0141 bincode is unmaintained
"RUSTSEC-2025-0141",
# https://rustsec.org/advisories/RUSTSEC-2026-0002 lru 0.12.x unsound IterMut
# pinned by reth fork at 0.12.5, fix requires 0.16.3 (semver-incompatible)
"RUSTSEC-2026-0002",
]

# This section is considered when running `cargo deny check bans`.
# More documentation about the 'bans' section can be found here:
# https://embarkstudios.github.io/cargo-deny/checks/bans/cfg.html
[bans]
# Lint level for when multiple versions of the same crate are detected
multiple-versions = "warn"
# Lint level for when a crate version requirement is `*`
wildcards = "allow"
highlight = "all"
deny = []
skip = []
skip-tree = []

[licenses]
version = 2
confidence-threshold = 0.8
# Ignore private workspace members entirely
private = { ignore = true }

# List of explicitly allowed licenses
# See https://spdx.org/licenses/ for list of possible licenses
# [possible values: any SPDX 3.7 short identifier (+ optional exception)].
allow = [
"MIT",
"MIT-0",
"Apache-2.0",
"Apache-2.0 WITH LLVM-exception",
"BSD-2-Clause",
"BSD-3-Clause",
"BSL-1.0",
"0BSD",
"CC0-1.0",
"ISC",
"Unlicense",
"Unicode-3.0",
"Zlib",
# https://github.com/rustls/webpki/blob/main/LICENSE ISC Style
"LicenseRef-rustls-webpki",
# https://github.com/briansmith/ring/blob/main/LICENSE ISC + OpenSSL + SSLeay
"LicenseRef-ring",
"CDLA-Permissive-2.0",
"MPL-2.0",
]

exceptions = [
{ allow = ["MPL-2.0"], name = "option-ext" },
]

[[licenses.clarify]]
name = "ring"
expression = "LicenseRef-ring"
license-files = [{ path = "LICENSE", hash = 0xbd0eed23 }]

[[licenses.clarify]]
name = "rustls-webpki"
expression = "LicenseRef-rustls-webpki"
license-files = [{ path = "LICENSE", hash = 0x001c7e6c }]

# This section is considered when running `cargo deny check sources`.
# More documentation about the 'sources' section can be found here:
# https://embarkstudios.github.io/cargo-deny/checks/sources/cfg.html
[sources]
unknown-registry = "warn"
unknown-git = "deny"
allow-git = [
"https://github.com/morph-l2/reth",
"https://github.com/rustyhorde/vergen",
]
Loading