Repository navigation
Commit 1f3247e
committed
CI: allow formal verification to run on pull requests from forks
Secrets are never passed to a workflow triggered by `pull_request` from a
forked repository, so the Certora job could not run on external
contributions: CERTORAKEY was always empty.
Split the formal verification workflow in two:
- `fv-certora.yml` runs the Certora job on `pull_request_target`, which
executes in the context of the base repository and therefore has access
to the secret. Access is gated behind the `certora` environment: with
required reviewers configured, the job waits for a manual approval
before it starts. Because the job checks out and runs the contributor's
code, that approval is the security boundary and reviewers must check
the diff for anything that could exfiltrate the key. Approval is
requested again on every push to the pull request.
- `fv-checks.yml` keeps `apply-diff` and `halmos` on plain
`pull_request`. Neither needs a secret, so they should not sit behind
an approval gate.
Requires, on the repository settings side: a `certora` environment with
required reviewers, holding CERTORAKEY as an environment secret, and
removal of the repository-level CERTORAKEY so that other workflows can no
longer reach it.1 parent f646874 commit 1f3247e
3 files changed
Lines changed: 81 additions & 66 deletions
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
0 commit comments