All posts

Nested agents: what they mean for your access reviews (on Azure)

When your Azure access reviews surface only the identities that actually touched a resource, you can retire stale permissions with confidence and avoid accidental over‑grant. In many organizations, engineers and automation bots share a handful of long‑lived service accounts. Those accounts often run a local agent that talks directly to a database, a Kubernetes cluster, or a remote host. Because the agent forwards the request without an intervening policy point, the original user’s token is neve

Free White Paper

Access Reviews & Recertification + Azure RBAC: The Complete Guide

Architecture patterns, implementation strategies, and security best practices. Delivered to your inbox.

Free. No spam. Unsubscribe anytime.

When your Azure access reviews surface only the identities that actually touched a resource, you can retire stale permissions with confidence and avoid accidental over‑grant.

In many organizations, engineers and automation bots share a handful of long‑lived service accounts. Those accounts often run a local agent that talks directly to a database, a Kubernetes cluster, or a remote host. Because the agent forwards the request without an intervening policy point, the original user’s token is never seen again. The result is a chain of "nested agents" where the true initiator is hidden behind one or more hops.

Azure AD access reviews rely on clear, auditable links between a principal and a resource. When a request passes through a nested agent, the audit log records the service account that the first agent used, not the human or upstream automation that triggered the flow. Over time, the service account accumulates permissions that appear "in use" even though no one directly interacts with it. Reviewers either keep the account alive out of caution or spend weeks untangling the chain to determine who really needs the access.

Two concrete symptoms illustrate the problem:

  • Stale service accounts linger in Azure AD groups because the access‑review UI shows them as active, even though they are only a technical conduit.
  • When a breach occurs, investigators struggle to trace the original request because the logs point to the outermost agent, not the inner caller.

What a proper precondition fixes – and what it still leaves open

Adopting non‑human identities for automation and enforcing least‑privilege IAM roles eliminates the need for shared passwords. Each bot now authenticates with its own OIDC token, and Azure AD can enforce time‑boxed roles. This step removes the obvious credential‑sprawl, but it does not solve the visibility gap.

Even with distinct tokens, the request still travels directly from the outer agent to the target resource. The gateway that forwards the traffic does not record the command, does not mask returned data, and does not require a human to approve risky operations. Consequently, access‑review data remains incomplete: the system knows *who* called the outer agent, but not *what* the inner agent actually did.

How hoop.dev resolves the gap

hoop.dev is a Layer 7 gateway that sits in the data path between any identity, human or service, and the infrastructure you protect. By proxying the connection, hoop.dev can enforce policy at the exact point where traffic leaves the network. Because the gateway owns the credential for the downstream target, the original principal never sees it, and every request passes through a single, auditable choke point.

Continue reading? Get the full guide.

Access Reviews & Recertification + Azure RBAC: Architecture Patterns & Best Practices

Free. No spam. Unsubscribe anytime.

When a nested‑agent scenario occurs, hoop.dev records the full session, including the command issued by the inner agent and the response returned by the resource. It can mask sensitive fields in real time, route suspicious commands to a reviewer for approval, and block operations that violate policy before they reach the backend. All of these enforcement outcomes are produced by hoop.dev because it is the only component that inspects the traffic.

For Azure access reviews, this architecture delivers three concrete benefits:

  1. Accurate entitlement data. The audit log emitted by hoop.dev ties each action to the original OIDC token, so reviewers see the true owner of every request, not just the service account that happened to forward it.
  2. Just‑in‑time permissions. hoop.dev can grant temporary access to a downstream resource only for the duration of the session, ensuring that long‑lived service accounts do not retain unnecessary rights.
  3. Evidence for compliance. Session recordings and inline masking provide the artifacts auditors expect when they ask for proof of who accessed what and when.

Implementing hoop.dev on Azure follows the same pattern used for any supported target: deploy the gateway near your resources, register each connection, and configure OIDC authentication with your Azure AD tenant. The official getting‑started guide walks you through the Docker‑Compose quick‑start, and the Learn site explains how masking, approvals, and session replay work in practice.

Practical steps for teams

  • Identify every service account that currently acts as a nested agent. Replace shared passwords with distinct OIDC identities.
  • Deploy hoop.dev in the subnet that hosts the most sensitive resources (databases, Kubernetes clusters, SSH endpoints).
  • Enable session recording and inline masking for all connections that flow through the gateway.
  • Configure Azure AD access reviews to consume the hoop.dev audit feed, so the review UI reflects the true initiator of each action.

By consolidating policy enforcement into a single, observable layer, you eliminate the blind spots that nested agents create and give your access‑review process the precision it needs.

FAQ

Do I need to change my existing Azure AD applications?

No. hoop.dev acts as a relying party for your OIDC tokens, so you can keep the same Azure AD app registrations. You only add the gateway as a trusted audience for those tokens.

Will hoop.dev add latency to my database queries?

The gateway operates at the protocol layer and adds only the processing time required for policy checks and optional masking. In most workloads the added latency is measured in milliseconds and is outweighed by the security benefits.

Can I still use existing CI/CD pipelines that run scripts against my clusters?

Yes. CI/CD jobs can obtain an OIDC token for a service‑account identity and then connect through hoop.dev just as a developer would. The pipeline gains the same audit and just‑in‑time controls without code changes.

Ready to tighten your Azure access reviews? Explore the open‑source repository on GitHub and start the quick‑start deployment.

Open source

Save the open-source gateway for agent data access

Hoop is MIT-licensed infrastructure for controlling how AI agents reach production data. Star hoophq/hoop so you can inspect it, deploy it, or share it when your team starts governing agent access.

Star and save the repo →More posts