Provenance depends on the integrity of the account and runner that produce the build attestation. If an attacker controls the repository, publishing account, or CI/CD pipeline, they can generate apparently valid provenance for malicious code. That means provenance must be paired with hardened source control access, runner governance, and audit logging.
How CI/CD Identity Becomes the Source of Trust
Package provenance is only as trustworthy as the identity that signs, attests, or publishes the build. In practice, that means the repository account, publishing account, and pipeline runner are not just delivery mechanics, they are the trust boundary that decides whether a build statement reflects a controlled process or an attacker-controlled one.
When those identities are compromised, the attacker can use the legitimate pipeline to create artifacts, generate attestations, and publish metadata that look authentic to downstream consumers. The provenance record may be structurally valid while still describing malicious code, because the system recorded trust in the wrong actor.
This is why provenance is strongest when the build path is constrained by hardened source control, tightly scoped runner permissions, short-lived credentials, and verifiable signing or attestation steps. A provenance statement proves that a pipeline emitted something, not that the pipeline itself was uncompromised.
What Actually Breaks When the Pipeline Is Owned
The failure is usually not in the provenance format. It is in the control of the identity that can mint it. If an attacker steals a publishing token, compromises a CI/CD service account, or hijacks a self-hosted runner, they can often preserve the outward appearance of normal release automation while substituting the payload, changing the build inputs, or reusing trusted signing paths.
That creates a dangerous symmetry: consumers see a legitimate attestation, but the attacker has already inherited the authority that produced it. Package provenance therefore depends on provenance of the build authority itself, including who can trigger builds, who can modify workflows, who can access artifacts, and who can approve release steps.
Strong pipeline identity controls, such as short-lived federated credentials and isolated runners, reduce this problem because the compromise window is narrower and the blast radius is smaller. The CI/CD Pipeline Identity Security Guide focuses on exactly those trust points, including workload federation, token scope, pinned actions, and signing discipline.
Why Provenance Needs Identity, Not Just Signatures
Signatures and attestations are necessary, but they do not solve trust if the signer has been captured. The real question is whether the signing key, build token, or release identity is bound to a controlled environment and a controlled workflow. If an attacker can operate inside that environment, they can often produce output that verifies correctly even though the inputs were malicious.
That is why provenance must be evaluated together with source control protections, runner governance, and logging. Source control access limits who can alter the build recipe. Runner governance limits what the build host can reach and whether it can persist secrets. Audit logging gives investigators a way to reconstruct whether an apparently trusted artifact came from a normal release path or from a hijacked one.
Build integrity frameworks make this distinction concrete. SLSA is directly relevant because it treats build provenance as a supply-chain integrity problem, while the Secret Sprawl Challenge shows how exposed CI/CD secrets turn a trusted delivery path into a credential theft path.
Standards & Framework Alignment
This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.
OWASP Non-Human Identity Top 10 addresses the attack and risk surface, while SLSA, NIST SP 800-53 Rev 5 and CIS Controls v8 set the governance and control requirements practitioners need to meet.
| Framework | Control / Reference | Relevance |
|---|---|---|
| SLSA | Supply-chain Levels for Software Artifacts | Build provenance is the core subject, and SLSA directly addresses artifact integrity and trusted build output. |
| Recommendation — Adopt SLSA controls to bind artifacts to trusted, verifiable build inputs and identities. | ||
| NIST SP 800-53 Rev 5 | IA-5 — Authenticator Management | Compromised pipeline identities often involve token or secret lifecycle failures that break provenance trust. |
| AU-2 — Event Logging | Audit logs are needed to reconstruct who produced or altered a build and whether provenance is trustworthy. | |
| Recommendation — Manage build credentials with short lifetimes, rotation, and revocation discipline. Log build, release, and signing events so artifact provenance can be investigated and proven. | ||
| CIS Controls v8 | CIS-5 — Account Management | CI/CD identity compromise is fundamentally an account and privilege control problem across build and publishing paths. |
| Recommendation — Restrict and review CI/CD accounts, service principals, and publishing access. | ||
| OWASP Non-Human Identity Top 10 | NHI-05 — Overprivileged NHI | Pipeline identities often have excessive rights that let attackers mint valid-looking provenance after compromise. |
| Recommendation — Reduce pipeline identity privileges to the minimum needed to build and publish. | ||
Practitioner Guidance
What to verify: Treat the attestation as untrusted until you can confirm which identity produced it, where the runner executed, and whether the workflow file, release token, and signing path were protected from modification. If any of those controls are shared broadly or persist for long periods, provenance assurance is weaker than it appears.
What good looks like: Use ephemeral, narrowly scoped build credentials; separate publishing rights from code contribution rights; pin workflow dependencies; and require logs that tie each artifact to a specific runner and commit. If your release process cannot answer “who had the authority to mint this build?” in a few minutes, the provenance story is incomplete.
Decision rule: If the compromise path includes repository admin, publishing credentials, or runner control, prioritise rotation, workflow lockdown, and artifact revalidation before trusting any downstream provenance claim.
Practitioner takeaway: Provenance is only meaningful when the identity that creates it is harder to compromise than the artifact it vouches for.
Related resources from NHI Mgmt Group
- What breaks when an npm maintainer identity is compromised in a CI/CD pipeline?
- What breaks when a compromised package executes during import in CI/CD pipelines?
- Who is accountable when a compromised package reaches CI/CD pipelines?
- How should security teams respond when a widely used package is published from a compromised maintainer account and malicious code reaches CI/CD systems?
Deepen Your Knowledge
Free weekly newsletter
Subscribe to the NHI & AI Identity Journal
The latest on NHI and Agentic AI security – articles, research, breaches, news and events every week.
Bonus 33% off our NHI Course when you subscribe.
Reviewed and updated by the NHIMG editorial team on October 12, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org