AI-Assisted Secure Coding (Appendix C) · CI/CD Pipeline Hardening Specific to AI Augmentation
Re-check open PRs after a workflow fix
Verify that the remediation of a vulnerable workflow includes invalidating or re-validating any PR that was opened before the fix landed. Without this step, a later commit to the same PR can pick up the stale workflow definition and route around the fix.
OWASP AISVS v1.01, requirement AC.12.8
In plain English
Fixing a vulnerable workflow file does not make existing pull requests safe. On some triggers, a PR opened before the fix can still run the old workflow definition when a new commit is pushed to it. As part of the fix, close or re-validate every PR that was open before it landed.
What good looks like
- The remediation checklist for workflow vulnerabilities includes dealing with open PRs.
- PRs opened before the fix are closed, or required to be brought up to date with the fixed base before any workflow runs.
- The same check covers long-lived branches that still carry the old workflow.
- The step is recorded for each remediation.
How teams usually do it
- A script using the platform API to list open PRs and branches created before the fix and close them or require an update.
- Requiring branches to be up to date before merging, and approval before workflows run on outside PRs.
Suggested evidence
- The remediation checklist.
- A past example with the list of PRs handled.
Common mistakes
- Fixing the workflow file and assuming the problem is over.
- Forgetting old release branches that still contain the vulnerable workflow.
Not sure which requirements apply to your system? Take the assessment, or browse every guide in this chapter.
Requirement text from the OWASP AI Security Verification Standard, licensed under CC BY-SA 4.0. This guidance is shared under the same licence.