Rightshold™ Sign up
Rightshold is live — the trust layer for AI agents.Launched November 23, 2026.Evidence Delivery$99 / 30 days · Offers are open — review the exact terms and the payment options shown on the service page before accepting.No token, everany ‘Rightshold token’ is not ours

Answers · agent safety

We're moving our AI agent off one shared API key so each customer's session uses that customer's own credentials, and we're looking at Amazon Bedrock AgentCore Identity's token vault. How does it keep one customer's tokens away from another customer's session, and where can that separation still break?

Last updated

TL;DR: By tying every credential lookup to a pair: the agent's workload identity and the end user it's working for. Your agent gets a workload access token that carries both, and the token vault only hands back credentials stored for that same agent-and-user pair, so tokens stored for customer A can't be read in customer B's session. The separation is only as good as the user identity you put in that token. If you exchange the customer's signed JWT (GetWorkloadAccessTokenForJWT), AgentCore checks the signature, issuer and expiry and uses the iss and sub claims. If you pass a plain user ID string (GetWorkloadAccessTokenForUserId), AWS says it treats the string as opaque and doesn't verify it, so whoever can call that API can name any customer. Two more gaps are yours to close: IAM decides which agents can use which credential providers, with no extra binding inside one account, and an OAuth consent link sent to the wrong person needs your own callback check.

What should I check, step by step?

1. Get the workload access token from the customer's own identity provider JWT (GetWorkloadAccessTokenForJWT) wherever you have one; AWS recommends that path for production.

  1. If you must use GetWorkloadAccessTokenForUserId, derive the user ID from the authenticated session on your side, never from a value the client or the model supplies.
  2. Grant bedrock-agentcore:GetWorkloadAccessTokenForUserId only to the principals that need it, scoped to specific workload identity ARNs, and deny it outright for workloads that always have a JWT.
  3. With more than one identity provider, prefix user IDs with the provider (cognito+user123, auth0+user123) so two customers with the same ID don't share a vault slot.
  4. Scope each agent's IAM Resource block to the exact workload identity and credential provider ARNs it needs, not *.
  5. Register an HTTPS callback in allowedResourceOauth2ReturnUrls and check that the user who finishes OAuth consent is the user who started it.
  6. Use AWS CloudTrail to watch GetWorkloadAccessTokenForUserId calls for user IDs you don't expect.

How does the AgentCore Identity token vault keep one customer's credentials from another's?

AgentCore Identity stores OAuth 2.0 tokens, OAuth client credentials and API keys in a token vault, encrypted with a customer-managed or service-managed AWS KMS key. Agents don't read the vault directly. They present a workload access token, an AWS-signed opaque token that, per the developer guide, contains both the agent's identity and the identity of the end user it's working for, and that works only for AgentCore's own services.

Where can per-customer credential separation break in Amazon Bedrock AgentCore Identity?

The user ID path is the main one. GetWorkloadAccessTokenForUserId takes a caller-supplied string and issues a token for that user and agent. AWS's guide says plainly that the platform treats the string as opaque and doesn't check it against an authenticated user, so the binding depends on the calling workload sending the right ID and on IAM being scoped tightly. A bug or a prompt injection that changes the user ID your code sends changes whose credentials the agent gets.

What should you log so an auditor can check one customer's AI agent credential trail?

AWS's guide says all credential operations are logged and recommends using AWS CloudTrail to watch GetWorkloadAccessTokenForUserId calls and to record which authenticated principal sent which user ID. That pairing is what shows a reviewer that a session for one customer never asked for another's credentials.

How do I ask Rightshold about this (free, no key)?

Add the MCP server https://www.rightshold.com/mcp to Claude, Cursor, ChatGPT, Grok or VS Code, then ask: “Give the agent working for one customer a Rightshold key that can only run license checks, labelled with that customer's account ID, and that stops working when this job's intent expires.”

One-click setup

{
  "tool": "intent_key",
  "arguments": {
    "intent_id": "<int_... from declare_intent, declared with operations [\"check_license\", \"check_rights_batch\"] and ttl_hours 8>",
    "label": "customer <account id> session"
  }
}

Rightshold isn't affiliated with Amazon Web Services. It doesn't run on or inspect AgentCore, IAM policies or token vaults. Behavior is as described in the Amazon Bedrock AgentCore developer guide pages on identity features, getting workload access tokens, scoping credential provider access, obtaining credentials and OAuth 2.0 authorization URL session binding, all read November 27, 2026; AWS updates these pages, so check the linked pages before relying on them.

What are the sources?

Related

Not legal advice. JSON · Markdown · All answers

Get a free API key in one call

No card and no email needed. 100 free credits; the license and policy checks stay free without a key.

curl -s -X POST https://www.rightshold.com/v1/accounts/signup -H "Content-Type: application/json" -d '{"accept_terms":true}'
export RIGHTSHOLD_API_KEY=rs_...   # the api_key from the reply (shown once)
curl -s https://www.rightshold.com/v1/licenses/check -H "Authorization: Bearer $RIGHTSHOLD_API_KEY" \
  -H "Content-Type: application/json" -d '{"license":"MIT","intended_use":{"commercial_use":true}}'