Without infrastructure and identity context, teams can approve changes that look safe in code but create exposure in deployment. A change may introduce risky cloud settings, weak API gateway controls, or overbroad identity permissions. The result is false confidence, because security review happens early but not comprehensively enough to reflect how the full product behaves.
Why This Matters for Security Teams
Shift-left only works when code review can see the real blast radius. For infrastructure and identity changes, that means understanding cloud roles, API gateway policy, secret handling, network paths, and the service-to-service trust chain before approval. Without that context, teams can bless a pull request that is clean in code but unsafe in deployment, which is exactly how least-privilege drift and overbroad access slip through review.
That gap is not theoretical. NHIMG’s Ultimate Guide to NHIs reports that 97% of NHIs carry excessive privileges, showing how quickly identity risk grows when controls are not evaluated against the live environment. The same pattern appears in infrastructure change management: the security issue is often not the code itself, but the permissions, trust relationships, and runtime dependencies that code activates. Current guidance from the NIST Cybersecurity Framework 2.0 supports governance across the full system lifecycle, not only the source artifact.
In practice, many security teams encounter the failure only after a deployment has already expanded access or exposed a service endpoint, rather than through intentional review of the full control plane.
How It Works in Practice
The practical fix is to shift-left with infrastructure and identity context attached to the change request. Security review should not stop at application logic. It should evaluate what the change does to IAM roles, workload identities, secrets, gateway rules, deployment permissions, and runtime reachability. A safe-looking YAML diff can still introduce a role binding that grants write access to storage, or a pipeline update that lets an agent or service account assume broader privileges than intended.
Teams usually get better outcomes when review gates consume metadata from cloud inventory, identity systems, and policy-as-code checks. That means validating the request against current state, not just intended state. For example:
- Compare the proposed role or policy against existing entitlements to detect privilege expansion.
- Check whether a new secret or token is long-lived, over-scoped, or stored outside a secrets manager.
- Review whether API gateway or network changes expose internal services to new callers.
- Require approval when a change affects production trust paths, not just when it changes application code.
This is also where identity context matters. NHI governance is not separate from infrastructure governance, because service accounts, keys, certificates, and automation tokens are part of the operational attack surface. NHIMG’s Top 10 NHI Issues and the 52 NHI Breaches Analysis both show how compromise frequently follows weak visibility, excessive privilege, or poor rotation. The right control pattern is to evaluate policy at request time with live context, using tools such as OPA or Cedar, then pair that with just-in-time access where practical. These controls tend to break down in highly dynamic multi-account cloud environments because identity relationships change faster than static review workflows can track them.
Common Variations and Edge Cases
Tighter infrastructure review often increases delivery overhead, requiring organisations to balance approval speed against the risk of authorising hidden privilege. That tradeoff becomes more visible in environments with autoscaling, ephemeral workloads, and AI-assisted change generation, where every change may be valid in isolation but unsafe in aggregate. Best practice is evolving here, and there is no universal standard for how much context must be attached to each review, but current guidance suggests the minimum should include identity, network exposure, and secret scope.
One common edge case is partial visibility. If the platform team owns cloud controls but application teams own the pipeline, no single reviewer sees the full exposure path. Another is delegated automation, where an agent or CI job can merge changes that later widen access in production. In those cases, approval based only on source diff creates false confidence because runtime behaviour is still unknown. NIST’s security lifecycle guidance and NHI-focused research both point to the same operational lesson: changes must be judged by what they authorize, not just what they modify.
For teams operating with strong separation of duties, the better model is to treat infrastructure and identity changes as governed assets, not implementation details. Otherwise, shifts that look like routine refactoring can quietly create persistent access, and persistent access is where shift-left programs most often lose their security value.
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, OWASP Agentic AI Top 10 and CSA MAESTRO address the attack and risk surface, while NIST AI RMF and NIST CSF 2.0 set the governance and control requirements practitioners need to meet.
| Framework | Control / Reference | Relevance |
|---|---|---|
| OWASP Non-Human Identity Top 10 | NHI-03 | Identity drift and excessive privilege are central to shift-left failures. |
| OWASP Agentic AI Top 10 | A2 | Agentic changes can widen access beyond what code review predicts. |
| CSA MAESTRO | GOV-2 | Governance must cover runtime trust paths, not only application code. |
| NIST AI RMF | GOVERN | AI-driven changes need accountable governance across the full lifecycle. |
| NIST CSF 2.0 | PR.AC-4 | Least-privilege access review directly addresses overbroad deployment permissions. |
Map identity and infrastructure controls into agent governance before enabling deployment actions.
Related resources from NHI Mgmt Group
- What breaks when teams can see exposure but not identity context?
- What breaks when identity teams try to clean up Active Directory without dependency mapping?
- How do infrastructure teams reduce identity technical debt without creating new risk?
- What breaks when AI model sprawl is tracked without identity context?