Learning Library

← Back to Library

Secure Identity Propagation in Agentic Systems

Key Points

  • Organizations adopting generative AI, RAG models, and agentic systems are encountering the challenge of securely propagating user identities throughout complex agent flows.
  • Traditional identity propagation patterns are reviewed, starting with **no delegation**, where the application accesses downstream services without any knowledge of the end‑user.
  • **Trusted assertion** introduces an identity provider (IdP) that authenticates the user and passes a SAML (or similar) assertion to downstream services so they can enforce user‑specific privileges.
  • **Simple delegation** shifts to token‑based delegation, where the application authenticates itself, obtains a token representing the user, and presents that token to downstream resources for access control.
  • The core questions for agentic systems become “how do we propagate identity?” and “what actions is the user authorized to perform?”, emphasizing the need for robust delegation mechanisms and fine‑grained privilege checks.

Full Transcript

# Secure Identity Propagation in Agentic Systems **Source:** [https://www.youtube.com/watch?v=wiU7VEvi1LM](https://www.youtube.com/watch?v=wiU7VEvi1LM) **Duration:** 00:13:58 ## Summary - Organizations adopting generative AI, RAG models, and agentic systems are encountering the challenge of securely propagating user identities throughout complex agent flows. - Traditional identity propagation patterns are reviewed, starting with **no delegation**, where the application accesses downstream services without any knowledge of the end‑user. - **Trusted assertion** introduces an identity provider (IdP) that authenticates the user and passes a SAML (or similar) assertion to downstream services so they can enforce user‑specific privileges. - **Simple delegation** shifts to token‑based delegation, where the application authenticates itself, obtains a token representing the user, and presents that token to downstream resources for access control. - The core questions for agentic systems become “how do we propagate identity?” and “what actions is the user authorized to perform?”, emphasizing the need for robust delegation mechanisms and fine‑grained privilege checks. ## Sections - [00:00:00](https://www.youtube.com/watch?v=wiU7VEvi1LM&t=0s) **Untitled Section** - - [00:03:07](https://www.youtube.com/watch?v=wiU7VEvi1LM&t=187s) **Token-Based Identity Propagation Risks** - The speaker outlines how authentication tokens are used to carry user privileges through multi‑agent chatbot workflows and warns that malicious agents could impersonate users to hijack and misuse those propagated identities. - [00:06:09](https://www.youtube.com/watch?v=wiU7VEvi1LM&t=369s) **Transitive Trust in Multi-Agent Systems** - The speaker discusses the challenges of establishing user trust across dynamic, multiple agents and separate identity providers spanning organizational boundaries, emphasizing the need for transitive trust rather than trust in individual agents. - [00:09:16](https://www.youtube.com/watch?v=wiU7VEvi1LM&t=556s) **Token Exchange in Agentic Flow** - The speaker explains that at each hop of an agentic flow, tokens should be exchanged with the identity provider to validate the user, confirm endpoint authenticity, and establish trust, preventing impersonation and aligning with OAuth 2.0 concepts. - [00:12:32](https://www.youtube.com/watch?v=wiU7VEvi1LM&t=752s) **API Gateways Centralize Token Exchange** - The speaker explains that placing token‑exchange logic in an API gateway offloads developers, standardizes identity propagation across agentic AI flows, and enables centralized monitoring for security and compliance. ## Full Transcript
0:00Howdy everyone. 0:01Organizations are embracing gen AI and rag models and agentic systems. 0:08With that, we're starting to see a lot of challenges pop up. 0:11One of the challenges we're seeing is how do we propagate an identity across an agentic flow? 0:27And we really want to kind of dig into this now and see in agentic systems, 0:31how are we going to securely propagate identities? 0:35To do this, we need to start and step back a little bit and look at 0:40kind of how we've evolved in identity propagation. 0:43Let's start with our user. 0:45And let's say that they're connecting to a database or some sort of system, 0:50something that they want to communicate with. 0:52We'll put a little application in here so a user has to connect to that. 0:56And it connects off to this system. 0:58So this will be our first pattern that we wanna start with. 1:01Now, as we go through this, we're gonna look at a set of delegation patterns. 1:12And these are the patterns, all the different patterns that exist that we want to kind of use. 1:16The first one we're gonna look at is no delegation. 1:23Now what this really says is that we have a user, they're gonna connect to this application. 1:28The application is going to connect to the database on its own. 1:32It has a secure connection or some sort of transaction set up here, 1:38and it doesn't know anything about the user. 1:40It doesn't need to know about the users. 1:42You connect, you return some information. 1:44That is what we call basically no delegation. 1:48The next thing we want to look at is what we call trusted assertion. 1:56Now we're going to start getting into the thought of, well, who is the user? 2:02This is really starting to get into identity propagation. 2:05So we're likely going to have an IDP. 2:08So this is an identity provider. 2:10The user comes in. 2:11They authenticate against this system. 2:14And then that is used to tell the database who that user is. 2:19So that user's going to some sort of privilege out here. 2:23And we want to use that. 2:24Now, in the case of trusted assertion, 2:27it's still this connection that we had before. 2:29The system and the database have some sort of credential passing, 2:32whatever it is they're using to make that connection. 2:35And I'm going to assert who the user is. 2:37And this can be in a SAML assertion. 2:39There's different ways to do this. 2:40But basically I will make the connection. 2:42I will pass that identity of the user into the database so I can 2:46check their privilege and return the right things. 2:50There's another model of this that we will look at another pattern that is simple 2:56delegation. 3:03Now in simple delegation, basically it's the same kind of thing. 3:07Instead of asserting who the user is, 3:08I'm gonna come in, I'm going to authenticate myself, I'm gonna create a token that token 3:14gets passed back and this becomes what I'm using for privilege. 3:17So as we look at our challenges, what we're really trying to look at is one, 3:22how are we propagating this identity? 3:24The next challenger, challenge, is what can the user do? 3:31And this really says, what am I allowed to access? 3:34What actions am I allow to take? 3:36All right, so this is great. 3:37This kind of brings us up to where we're at in our systems today, 3:42but now let's start introducing agentic. 3:44So let's say that we're interfacing with a chatbot up front, 3:49and that's our first interaction, 3:50and then maybe that goes to a router, 3:54and then that goes another agent. 3:57So now we've introduced an agentic flow, there are multiple nodes and hops, 4:01and let's say, just to keep this going, that we check here with our identity provider, 4:08we authenticate ourselves, here is who I am, get my identity, 4:12and then we want to propagate that identity through the system. 4:17So when we start thinking about what are the challenges, what are problems with this, 4:24what happens then if we have a bad actor who actually creates some agent or system 4:32on their own and they connect here to the router and they pass in an identity. 4:37They actually start impersonating you. 4:40So this is Edwina Cutwater impersonating Roger Cobb and wants to be able to 4:45take whatever privileges that that user has and propagate it through. 4:50So if we're just merely propagating the identity from the starting point in, 4:54how do we prevent that somebody inserts and says, hey, I am the identity of this person, 4:59and now please give me back all the stuff that we want to, 5:03that that person would be entitled to retrieve? 5:05So this really then starts talking about our next challenge, 5:10which is really then, how do trust the identity? 5:18In other words, how does this agent down in this flow or an 5:22agent up in this low or any flow that has created, how does it know? 5:26It has no visibility to where this user came in and originally authenticated themselves. 5:31How do they trust that the identity that is coming through the system is actually the 5:36identity that is supposed to be used 5:38and the privileges and the data, whatever it is that we're trying 5:41to protect is actually going back to the person that we think it is. 5:44So that becomes our next challenges. 5:47How do we really then, from these systems, trust the identity? 5:51I'm gonna introduce now another delegation pattern, which is on behalf of delegation. 6:01Now this starts getting into a model where we have an agent and a user, 6:07both of them are going to have identities. 6:09They're both gonna be part of, they're gonna have tokens, 6:12they're going to privileges, they're go have rights. 6:14Now the agent is going to work on behalf of the user. 6:18And the user trusts that agent, it knows who this agent is, and it trusts it to act on your behalf. 6:24Now, what happens if we have multiple agents? 6:26What happens if in agentic flows it's very dynamic and agents get introduced into this system? 6:32How does the user then know to trust all the agents down throughout the system? 6:38And this really starts introducing yet another 6:41challenge, is how do we have a user accept transitive trust. 6:52In other words, the user is not actually trusting an individual agent. 6:55What they're doing is they're trusting the system to act and behave on their behalf. 7:02All right, I'm going to introduce one final now pattern here. 7:06And this is multiple IDPs, identity providers. 7:14So what this really looks like then let's say that this is all a system here. 7:20This is a company. 7:21This is an organization. 7:22Let's say this is company A 7:27and we have another organization, we'll call this Company B, 7:36and we're actually talking across organizational boundaries. 7:39This could even be within divisions if things are really separated within a company, 7:43but the point is, is we now have separate identity providers within these two organizations. 7:49We may even have, as we cross over boundaries, 7:52another router that figures how to send an agentic flow to get a prompt and a response, 7:57but now we have to deal with independent ID providers and independent systems. 8:02So we have across this. So these are the patterns and the challenges that we are really seeing emerging, 8:09especially around identities and identity propagation in organizations. 8:14And so let's start thinking about what are our strategies then. 8:19To how to deal with this. 8:21Now, of course, this is an emerging space, it's an emerging world. 8:24The strategies I'm gonna outline here will work, 8:27but they will also evolve as we start evolving agentic systems. 8:31So the first thing that we really wanna look at as a strategy is we really want to use 8:39OAuth 2, 8:43and OIDC, OpenID Connect. 8:46So this really says, let's stick to the standards. 8:48We have standards on how to identify users and what their rights and privileges are. 8:53Let's use that as our common base for talking. 8:56This works really well if we have company A talking to company B, 9:00they both operate on industry standards. 9:02That makes it very easy to do this interaction. 9:05So first thing we wanna do is use OAuth 2 and OIDc as our standards. 9:10The next thing we want to do, is introduce a concept of a token exchange. 9:18What this is really saying is that at each node along an agentic flow, 9:26we actually want to go back to the IDP and we want to do an exchange of the ticket. 9:31So we started with an original token. 9:34We started with the original token here and we flowed that token through, 9:38but each hop we actually wanna go exchange that token, 9:41Aad this way we can really start looking at how do we validate that the user is the right user. 9:48And really what this is starting to say is, if you remember back here, 9:51we had this kind of a secure connection between this application and the database, 9:56and we understood that connection. 9:58Now, when we think about an agentic flow, it is an established flow. 10:01We know endpoints, we know each hop along the way. 10:05If at each hop, we evaluate and look at to make sure that the incoming endpoint, 10:10the outgoing endpoint that we know are all the correct ones, we can exchange our token. 10:16To make sure it works for that hop. 10:18So that way, we can start preventing people 10:20from coming and impersonating and injecting themselves into the flow 10:24because it would not match our known flow and it would match our know end point. 10:29So we can starting eliminating that. 10:31So what it really kind of does then for us is it verifies our identity. 10:41And it establishes trust. 10:47We can even do this across company organizations as well, 10:50same kind of establishment of trust. 10:52All right, so we do a token exchange. 10:54Next thing we want to do then, and this really starts playing 10:59into the OAuth 2.0 concept is we want the leverage context. 11:05We want to leverage scope and we want a leverage audience. 11:11Now, this is really, really nice and important because what this is saying, 11:15is that we don't want the user at the very beginning of our agentic flow. 11:19We don't wanna say that they can do anything across the entire company, across the enterprise. 11:24As they move along the nodes, as we have a context of the token that's moving through, 11:29we want to only allow them the scope, or what they're authorized to do, 11:34to be very narrow, and really ultimately narrow down to just the access to this database, 11:40and along every node we want the narrow that scope 11:42to what they are allowed to do along that process flow. 11:46The other thing by adding audience we can say when we do this token 11:50exchange that we know the next hop and we say that is our audience. 11:54So when an agent somewhere in the flow receives an exchange token, 11:59it should see itself as the audience. 12:01It knows it has now taken the next action. 12:03If the audience is incorrect or non-existent, it knows to reject that out. 12:07So again, that starts preventing injections into this flow with impersonated identities. 12:13So we really want to leverage some of 12:15the capabilities and features that we're seeing in OAuth 2. 12:19The next strategy we have, is we want to connect our nodes, our agents, and our flow via APIs. 12:32So what this is really saying is we use API gateways. 12:36We understand APIs, we understand REST APIs, we understand API economies. 12:40We know that if we just pass, connect through from one node 12:44to another along our agentic flow, and that goes through an API gateway, 12:48it's that gateway now that can have the responsibility of doing the token exchange. 12:53It's actually the thing that's going and exchanging the token. 12:56That takes the burden off of the developers so they don't have to understand token exchanges. 13:01It also centralizes, at least within an organization, 13:05how we're going to do the token exchange. 13:07So it brings a lot of value to how we perform 13:11these strategies or how we execute on these strategies. 13:14The final thing, and this is something we always wanna do, is monitor. 13:19You know, when we start talking about compliance and security across the board, 13:23we always want to monitor what is happening across that. 13:27Agentic flow and make sure that the identity propagation is actually behaving the way we want. 13:32Alright. So we know companies and organizations are embracing gen AI and agentic flows. 13:39We know that there is a challenge with how do you propagate that 13:43identity across that flow to make sure  it is securely being used and leverages. 13:48And I have presented a few strategies on how you can accomplish that. 13:52Thank you very much.