English edition · cyberattaques.org in FrenchFrançais
Solution

AWS IAM previews a unique identity for each AI agent and workload, replacing long-lived secrets

AWS has released in preview IAM agent and workload identity, which gives every workload and AI agent a unique identity that AWS STS verifies before issuing short-lived credentials. It matters to teams running workloads on Amazon EKS or agents on Amazon Bedrock AgentCore that currently rely on stored secrets.

What to do now Illustration photo (cloud server identity security)

AWS has opened a preview of an IAM capability called agent and workload identity. It gives each workload, AI agents included, a unique identity that is managed centrally across an organization. Before AWS Security Token Service (STS) issues short-lived credentials, it checks attested facts about the workload. The preview supports Amazon EKS, Amazon Bedrock AgentCore Runtime and Amazon Bedrock AgentCore Gateway. It comes at no additional charge in AWS commercial Regions.

The security gain comes from dropping long-lived secrets. A workload's identity is no longer a credential that someone creates and hands over; it is derived from what the workload actually is. When an EKS pod starts, the service sends STS facts the pod cannot alter, such as its cluster, namespace and service account. STS compares them with the attestation policy attached to an identity template, and withholds the identity if they do not match. AgentCore Runtime and Gateway supply these facts from their own control plane, with no extra setup.

The design has three parts. The first is a provider created in IAM, which acts as the root of trust. It defines a trust domain such as corp.example.com, path prefixes that carve the namespace up by account or team, and JWT signing keys generated by IAM. During the preview, SPIFFE is the only supported identity scheme. The second is the workload identity template, which builds each identifier from values such as account, Region, cluster, namespace or runtime name, and sets the conditions a workload must meet. The third is the set of credentials the workload receives.

A workload can receive three kinds of credentials. For calls to AWS services, it gets an IAM role session that carries its identifier. CloudTrail records that identifier as onBehalfOf.subject, and policies can match it with the aws:OriginIdentity/Subject condition key; the attesting service can cap the session at anywhere from 15 minutes to 12 hours. For services that accept JWT authentication, it gets a JWT-SVID signed by STS, valid for up to one hour. For mutual TLS, it gets an X.509-SVID issued by your AWS Private CA, valid for 12 hours by default and configurable from 1 to 12 hours. The AWS SDKs pick up these credentials through the default credential provider chain, so existing code does not need to change.

AWS points out one configuration trap. An identifier is unique only within its provider, so policies should check aws:OriginIdentity/Subject and aws:OriginIdentity/Issuer together. Amazon S3 Block Public Access treats a bucket policy that checks the subject alone as public. Certificates have their own prerequisite: STS calls the AWS Private CA IssueCertificate API using the workload's role session, so that role needs permission to issue certificates from the CA.

For services outside AWS, STS publishes the provider's OIDC discovery document, public signing keys and SPIFFE trust bundle. A SaaS or on-premises service can therefore verify a workload's credential without holding any AWS credentials of its own. With a SaaS API, the agent presents its JWT-SVID instead of a client secret and receives a short-lived access token in return. Depending on what the provider supports, this usually happens through OAuth 2.0 token exchange (RFC 8693) or the JWT bearer grant (RFC 7523).

At organization level, only the management account or an IAM delegated administrator can create, change or delete providers and templates. IAM places a read-only copy in each member account. Authorization is still evaluated in the account, where identity policies, SCPs and RCPs continue to apply, so an organization-level resource grants no new permissions. Each template gets a default attestation policy. AWS recommends writing a tighter one when the default admits more workloads than intended, for example to restrict identities to one cluster or to production namespaces.

Action plan

What to do now

  1. List the EKS workloads and Bedrock AgentCore agents that currently authenticate with stored secrets, so you know which ones are candidates for this preview.
  2. Trial the feature in a non-production account using AWS's getting-started guide, which covers the provider, an EKS template, a Pod Identity association and an S3 bucket policy.
  3. In every policy that relies on these identities, check aws:OriginIdentity/Subject and aws:OriginIdentity/Issuer together, otherwise S3 treats the policy as public.
  4. Replace the default attestation policy with one scoped to the intended clusters, namespaces or runtimes wherever a template admits more workloads than you want.
  5. As general good practice, avoid making critical production access depend on a preview feature until it reaches general availability.

Sources