Repository navigation
Conversation
…quest vulnerability - Create docs-pr.yml: triggered by pull_request (no secrets), safely builds fork docs and uploads artifact - Update docs-deploy.yml: remove pull_request_target trigger, add workflow_run trigger; preview job downloads pre-built artifact only and never touches fork code - Update docs.yml: clarify ref input accepts SHA or full ref
|
@copilot |
This duplication is transient and specific to this PR. Once this PR is merged:
No code change needed — the duplication disappears automatically when the PR lands. |
|
I will review this tomorrow :( |
|
@copilot What triggered you to open this PR? |
|
I was playing around with Btw, it always shows who did this:
|
|
Interesting, it looks like a hidden event that only you can see because the anchor takes me to the top of the page but I see nothing. |
|
Superseded by #1101 |
docs-deploy.ymlusedpull_request_target(which holdsCF_ACCOUNT_ID/CF_PAGES_TOKEN) and delegated todocs.yml, which checks out and executes fork code — a classic pwn-request path.actions/checkout@v7now refuses this combination outright.Changes
.github/workflows/docs-pr.yml— triggered bypull_request(no secrets); callsdocs.ymlto build fork code and upload the artifact safely in the untrusted context..github/workflows/docs-deploy.yml— removespull_request_target; adds aworkflow_runtrigger that fires afterdocs prcompletes. The newpreviewjob downloads the pre-built artifact and deploys it — fork code is never executed in this context..github/workflows/docs.yml— updatesrefinput description to clarify it accepts a SHA or full ref.Trust boundary
pull_requestworkflow_runpushto mainThe artifact is the boundary: untrusted runner builds HTML, trusted runner deploys the already-built output.