AI-Assisted Secure Coding (Appendix C) · CI/CD Pipeline Hardening Specific to AI Augmentation
Approve secret-bearing jobs for forks
Verify that secrets are not exposed to workflows running code from forks or first-time contributors. Environment-protection rules (or the platform equivalent, such as protected variables and deployment approvals) require a manual approval before any secret-bearing job runs for those contributions. This control pairs with AC.11.7 and AC.13.2. Bot-level enforcement under AC.11.7 does not substitute for the platform-level enforcement required here.
OWASP AISVS v1.01, requirement AC.12.3
In plain English
Workflows that run code from forks or first-time contributors must not have access to secrets. Use the CI platform's own protection, so that a person approves before any secret-bearing job runs for those contributions. A bot being told to behave (AC.11.7) does not replace enforcement by the platform.
What good looks like
- Secrets are not exposed to workflows running fork or first-time contributor code.
- Jobs that use secrets sit behind environment protection rules, or the platform's equivalent, which require manual approval.
- The approver sees what they are approving, including any workflow changes.
- The control is enforced by the platform, in addition to bot-level and contributor-level checks.
How teams usually do it
- Protected environments with required reviewers on GitHub, protected variables and deployment approvals on GitLab, or the equivalent elsewhere.
- Organisation settings that require approval before workflows run for outside contributors.
- Moving secrets from repository level to environment level, so they are only reachable through the gate.
Suggested evidence
- Environment and repository settings.
- An approval record for a fork contribution.
Common mistakes
- Relying on the bot to refuse when the platform would hand over the secret.
- Repository-level secrets available to every workflow.
- Approvers who click through without reading the diff.
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.