Agentic AI Module Added To NHI Training Course

Who should be accountable for secrets hidden inside build and release pipelines?

Ownership should sit with the teams that operate the workflow and the identity controls that authorize it, not with the security team alone. If a pipeline can reach production systems, package registries, or internal repositories, its credential posture belongs in governance reviews, access recertification, and incident response planning.

Why This Matters for Security Teams

Secrets hidden in build and release pipelines are not a tooling nuisance. They are production-grade access paths that can unlock registries, deployment targets, cloud APIs, and internal systems. That means accountability has to sit with the workflow owners, platform engineers, and identity approvers who can change the pipeline, not with security alone. The control problem is governance: who can issue, use, review, and revoke the secret.

NHIMG research shows why this is urgent. In The State of Secrets Sprawl 2026, GitGuardian found that 59% of compromised machines in a major supply chain attack were CI/CD runners rather than personal workstations. That is a strong signal that pipeline identity has become a primary attack surface. The Reviewdog GitHub Action supply chain attack and the CI/CD pipeline exploitation case study show the same pattern: attackers do not need to break the application when the release path already carries trust.

OWASP Non-Human Identity Top 10 treats machine credentials as first-class identities, which is the right lens here. In practice, many security teams encounter secret ownership only after a leaked runner token or deployment key has already been used to move laterally, rather than through intentional governance.

How It Works in Practice

Good ownership starts by assigning each pipeline secret to a business service and a technical custodian. The service owner explains why the secret exists; the platform or DevOps owner manages how it is injected, scoped, rotated, and revoked; and the security function audits whether that arrangement still matches risk. This is why secrets in build systems belong in access recertification, joiner-mover-leaver processes, and incident response runbooks.

Current guidance suggests the safest pattern is to avoid long-lived static secrets wherever possible. Use short-lived workload credentials, JIT provisioning, and vault-backed delivery so the pipeline receives only what it needs for the current job. The Guide to the Secret Sprawl Challenge and the JetBrains GitHub plugin token exposure both reinforce the same operational lesson: secrets spread fastest when teams treat convenience as a substitute for governance.

Practitioners should also separate the secret from the pipeline persona. A runner or agent should authenticate as a workload identity, then receive narrowly scoped authorisation at request time. That means:

  • binding each pipeline to a distinct workload identity rather than sharing a generic token
  • scoping access by environment, branch, repository, and deployment stage
  • issuing ephemeral credentials with clear TTLs and automated revocation
  • logging every secret fetch, use, and rotation event for review

OWASP Non-Human Identity Top 10 is useful here because it frames secrets as identity lifecycle issues, not just storage problems. These controls tend to break down when one shared pipeline token is reused across multiple repos, environments, and release jobs because revocation then becomes all-or-nothing.

Common Variations and Edge Cases

Tighter secret control often increases release overhead, so organisations have to balance developer speed against blast-radius reduction. That tradeoff becomes more visible in monorepos, ephemeral preview environments, and external build farms where a single workflow may touch many systems in quick succession.

There is no universal standard for this yet, but best practice is evolving toward explicit ownership for every credential class, including those embedded in YAML, runner variables, and third-party actions. The important exception is break-glass access: if a pipeline must retain a high-risk credential for resilience, its ownership should be even more tightly defined, with separate approval, expiry, and monitoring.

Teams should also avoid the false comfort of private repositories. NHIMG research in The State of Secrets Sprawl 2026 shows that internal repositories are 6x more likely to contain secrets than public ones, which means hidden credentials are often a process failure, not an exposure-failure. In larger estates, the cleanest model is to assign ownership to the workflow product team, enforce identity-backed approvals, and review the secret posture alongside release risk. Where pipelines are federated across vendors or temporary runners, accountability must follow the execution path, not the org chart.

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 address the attack and risk surface, while NIST CSF 2.0 and NIST Zero Trust (SP 800-207) set the governance and control requirements practitioners need to meet.

Framework Control / Reference Relevance
OWASP Non-Human Identity Top 10 NHI-03 Covers secret lifecycle and rotation for machine identities in pipelines.
NIST CSF 2.0 PR.AC-4 Addresses least-privilege access for non-human pipeline identities.
NIST Zero Trust (SP 800-207) SC-7 Supports runtime trust decisions and segmentation for CI/CD identities.

Assign an owner for every pipeline secret and enforce rotation, revocation, and recertification.