GitHub actions/checkout v7: Security and Breaking Changes
GitHub actions/checkout v7 is released. See the v7.0.1 status, July 20 backport, allow-unsafe-pr-checkout change and migration checks.
Current release status: actions/checkout v7.0.1
Verified September 1, 2026: actions/checkout@v7 is released. GitHub published v7.0.0 on June 18, 2026 and v7.0.1 on July 20. The patch release narrows false positives for default checkout, trims only ASCII whitespace for branch handling, escapes values passed to --unset, and updates dependencies.
GitHub also moved the supported-version backport enforcement date from July 16 to July 20, 2026. Repositories using a floating supported major tag received the new behavior through the backport; exact SHA, minor, or patch pins still require an intentional update.
Use actions/checkout@v7 for the current major. If a privileged fork workflow now fails, do not add allow-unsafe-pr-checkout: true automatically. First separate untrusted build/test work into pull_request with reduced permissions or redesign the privileged step so fork code is never executed with secrets.
Yes. GitHub released v7.0.0 on June 18, 2026 and lists v7.0.1 as the current patch release.
GitHub released actions/checkout v7 with a security default that blocks common pwn-request patterns in privileged fork pull request workflows. GitHub scheduled the same enforcement for supported major versions on July 20, 2026. Floating tags such as actions/checkout@v4 are expected to receive it automatically, while workflows pinned to a SHA, minor version, or patch release must upgrade deliberately.

What changed in actions/checkout v7
GitHub changed actions/checkout so privileged workflows stop fetching fork pull request code in the riskiest common cases. The block applies to pull_request_target workflows and to workflow_run workflows when the original event was a pull request event.
The refusal is triggered when the pull request comes from a fork and the checkout resolves to the fork repository, a refs/pull/.../head or refs/pull/.../merge ref, or the fork pull request head or merge commit SHA. Same-repository pull requests are not affected, and the regular pull_request event is unchanged.
Key takeaways
actions/checkout@v7is already generally available with the safer default.- July 20, 2026 is the backport date for currently supported major versions.
- Floating major pins should receive the behavior automatically; exact pins need manual updates.
- The opt-out flag is
allow-unsafe-pr-checkout, and it should be treated as a security exception. - The guardrail does not cover manual
git, GitHub CLI, custom scripts, unrelated third-party repositories, or other event types such asissue_comment.
| Workflow pattern | New behavior | What to check |
|---|---|---|
pull_request_target plus fork PR checkout | Blocked by actions/checkout in common cases | Remove the checkout or move untrusted tests to pull_request |
Floating major pin such as actions/checkout@v4 | Backport expected on July 20 | Watch CI for failing unsafe checkouts |
| Exact SHA, minor, or patch pin | No automatic backport | Upgrade through Dependabot or your release process |
allow-unsafe-pr-checkout: true | Explicit opt-out | Require review, documentation, and narrow permissions |
Manual git or gh checkout | Not covered | Audit scripts that fetch and execute fork code |
Practical LinkLoot angle
This is a rare security update that can both prevent compromise and break CI in the same week. Audit workflows that combine elevated permissions with forked pull requests, package installs, local actions, generated artifacts, cache restore/save steps, or OIDC publishing access.
For automation-heavy teams, this belongs in the same review queue as AI-assisted workflow automation and release-bot permissions. Start with repositories that publish packages, deploy previews, write comments with privileged tokens, or run tests for external contributors.
What to verify before you act
- Search for
pull_request_targetandworkflow_runworkflows that callactions/checkout. - Check whether checkout is pinned to a floating major, exact SHA, minor version, or patch version.
- Look for
ref: ${{ github.event.pull_request.head.sha }},refs/pull/..., orrepository: ${{ github.event.pull_request.head.repo.full_name }}. - Review any
allow-unsafe-pr-checkoutuse as a privileged exception, not a convenience flag. - Confirm manual
git,gh, shell, cache, and package-install steps are not rebuilding the same pwn-request path outsideactions/checkout.
Source check
Confirmed by GitHub: actions/checkout v7 refuses common pwn-request patterns by default, the backport date is July 20, 2026, and exact pins are not automatically covered.
Independent context: The Hacker News corroborates the rollout and explains why pull_request_target can expose secrets and privileged GITHUB_TOKEN access when paired with untrusted fork code.
For adjacent automation reviews, see LinkLoot's guide to AI workflow automation.
It now refuses common unsafe fork pull request checkouts in privileged pull_request_target and certain workflow_run workflows.
Try the related loot
UI-TARS Desktop is a serious local computer-use agent — if you lock down the setup
