26 Nov, 2026Nitin Mandale
A Practical GitHub Actions Security Checklist for Engineering Teams
A CI workflow can read your code, access credentials, and publish artifacts. Treat changes to it with the same care as changes to production infrastructure. Use this checklist to assign ownership and reduce common GitHub Actions risks.
1. Limit token permissions
Owner: repository and workflow maintainers. Start with read-only GITHUB_TOKEN permissions and grant additional access only to jobs that need it. For example, a checkout-only workflow may start with:
permissions:
contents: read
Review write permissions on release and deployment jobs separately. Protect workflow changes with review rules. GitHub's secure use guidance explains least privilege and workflow risks.
2. Review and pin actions
Owner: platform team. Review third-party actions and reusable workflows before adoption. Pin actions to a verified full-length commit SHA and maintain a process to review updates. GitHub also documents workflow dependency lockfiles as a way to lock dependencies and verify their sources. A pin reduces unexpected changes; it does not make the pinned code safe.
3. Separate untrusted pull requests
Owner: workflow maintainers and security team. Avoid running untrusted PR code in privileged workflows. In particular, review uses of pull_request_target and workflow_run: checking out untrusted code or consuming untrusted artifacts in a privileged context can expose secrets and write access. Treat PR titles and other user-controlled inputs as data, not shell script content.
4. Restrict secrets and cloud access
Owner: cloud and security teams. Store credentials in GitHub secrets, limit which jobs and environments can use them, and protect sensitive deployments with environment rules. Where supported, use OIDC for short-lived cloud credentials. Scope the cloud trust policy to the intended repository and branch or environment; granting id-token: write alone is not a cloud authorization policy.
5. Verify artifacts before release
Owner: release team. Treat artifacts from untrusted workflows as untrusted input. For released binaries or images, generate and verify artifact attestations, checking the expected source and workflow against your policy before deployment. Provenance helps establish where an artifact came from; it does not prove the artifact is safe.
6. Control the runner lifecycle
Owner: platform team. Restrict which repositories can use self-hosted runner groups, and avoid exposing sensitive runners to untrusted PRs. For isolated jobs, consider GitHub's just-in-time runners and ensure the underlying environment is clean between jobs. Forward runner diagnostic logs to durable storage before ephemeral runners disappear.
Turn the checklist into a routine
Assign owners, review exceptions, and revisit controls as workflows change. Monk CI Shield helps teams review security findings and repository policy gaps across covered repositories. Its Monitoring mode reports findings without blocking merges; teams still configure workflow permissions, trusted triggers, runner isolation, and deployment policies themselves.