IAM Agent and Workload Identity on EKS: Per-Pod SPIFFE Names, Preview Limits

2026-12-02来源 dev.toEnglish

TL;DR

  • IAM can now give each agent or workload its own verifiable SPIFFE identity, on top of the IAM role it already uses. On EKS it is delivered through Pod Identity.
  • Preview, announced 1 December 2026. All commercial Regions for IAM; EKS excludes Bahrain and UAE. No extra charge in preview, but X.509 certificates bill through AWS Private CA.
  • Do first: pick one low-risk workload, give it its own service account, and write one bucket policy that names its identity.
  • My view: the "which pod did this" question finally has a clean answer. Preview rules apply, so pilot it and don't build your estate on it yet.

Contents

  • What launched
  • How it works
  • Turning it on for a pod
  • Limits and sharp edges
  • What this means for you
  • Related posts
  • Sources

What launched

On 1 December 2026 AWS announced two linked previews. IAM got agent and workload identity, and EKS added support for it through Pod Identity.

The idea is simple. A role says what a caller can do. It does not say which caller it is. Ten pods can share one role, and the only way to tell them apart afterwards is the role session name. This feature adds a name per workload to the role session, so policies and logs can see it.

Item Detail
Status Preview, docs say "subject to change"
Identity standard SPIFFE, with names you choose in a trust domain you own
Supported compute EKS, AgentCore Runtime, AgentCore Gateway
Regions (IAM) All commercial Regions, usable where EKS and AgentCore exist
Regions (EKS) All commercial except Middle East (Bahrain) and Middle East (UAE); not GovCloud (US) or China
Price No additional charge during preview; post-preview pricing not stated
Extra cost AWS Private CA charges if you issue X.509 certificates
EKS agent version Pod Identity agent add-on v1.5.0-eksbuild.3 or later
EKS Auto Mode AMI released 18 November 2026 or later

I found no AWS News Blog post for this one. Everything here comes from the two launch posts, the IAM user guide and the EKS user guide page. I have not run any of it.

How it works

You set up a provider once. It is the issuer and sets the trust domain, for example corp.example.com. It can live in one account or cover a whole organisation. Then you create templates. A template builds a name for every workload in a group from attested facts, and carries an attestation policy that decides who gets a name at all. Per the IAM guide, with no attestation policy, no identity is issued.

At runtime, the platform that runs the workload, not the workload, reports facts about it to STS. If they match the policy, STS builds the name and the role session carries it. For EKS the facts are cluster name and ARN, namespace, service account, pod name and UID, and node name.

A workload ends up holding three kinds of credential, all short-lived:

Credential Use it for
Role session (SigV4) with identity attached Calling AWS. The SDK uses it with no code change on EKS
JWT-SVID Bearer-token calls to your APIs and third parties
X.509-SVID mTLS in a mesh or between services

The identity is not an IAM principal. You name it in the Condition block, not in Principal. The two condition keys that matter are aws:OriginIdentity/Subject (the name) and aws:OriginIdentity/Issuer (the provider). The guide says to match both, because a name is only unique within its provider.

The EKS page frames it as who versus what. The role is the what. The identity is the who. It sits on the existing Pod Identity association, so pods with and without it can run side by side.

Turning it on for a pod

The EKS guide's walkthrough scopes an S3 bucket to one service account. The steps, in short:

  1. Create a provider and a template in the IAM console.
  2. Enable workload identity on the Pod Identity association.
  3. Restart the pods, because identity is applied when a pod is created.
  4. Add a bucket policy that names the workload.

The EKS guide also has a trust policy step for the role, which the IAM guide contradicts. I cover that under limits below.

Step 2 uses the documented workloadIdentityConfig. This is the guide's CLI example, with its placeholder values:

aws eks update-pod-identity-association \ --cluster-name prod-cluster-1 \ --association-id <association-id> \ --workload-identity-config '{ "enabled": true, "templateArn": "arn:aws:iam::111122223333:workload-identity-template/eks-prod-1", "providerArn": "arn:aws:iam::111122223333:workload-identity-provider/payments-prod" }' 

And the bucket policy, adapted from the same guide. Note the aws:PrincipalAccount line. Without a condition like it, S3 Block Public Access treats a "Principal": "*" policy as public and rejects it.

{ "Version": "2012-10-17", "Statement": [ { "Sid": "AllowCheckoutWorkload", "Effect": "Allow", "Principal": "*", "Action": "s3:GetObject", "Resource": "arn:aws:s3:::amzn-s3-demo-bucket/*", "Condition": { "StringEquals": { "aws:PrincipalAccount": "111122223333", "aws:OriginIdentity/Subject": "spiffe://payments-prod.111122223333.aws.internal/us-east-1/eks/prod-cluster-1/ns/payments/sa/checkout-sa", "aws:OriginIdentity/Issuer": "arn:aws:iam::111122223333:workload-identity-provider/payments-prod" } } } ] } 

The guide's test is the part I like. A pod using a different service account but the same role gets AccessDenied, as long as the role has no access of its own. Same role, different workload, different outcome.

Both snippets are copied from the AWS docs with placeholders. They are syntax-checked only, not deployed by me.

Limits and sharp edges

This is where I'd spend my reading time. Several items come straight from the EKS guide's limitations list.

  • Existing pods do not change. Identity is applied at pod creation. Enable it, then roll the workload.
  • Service account is the default grain. Every pod under one service account gets the same identity. If you want per-workload attribution, you need a dedicated service account each.
  • Per-pod names break policies. A custom template can include pod name, UID or node name. Those change when a Deployment replaces pods, so a policy naming one exactly stops matching after a rollout. StatefulSet names are stable.
  • No image-level scoping. The container image is not an attested fact.
  • Same account only. Assuming a role in a different account through this path is not supported on EKS. Federating the identity straight into another cloud's identity system is also not supported.
  • Istio ambient mode is not supported. Sidecar mode is.
  • Nitro Sandbox is not supported.
  • AL2 is not supported. AL2023-based EKS-optimised AMIs and Bottlerocket are.
  • No add-ons API. The podIdentityAssociations setting on an add-on cannot enable it. Use the association APIs directly.
  • JWT caching. The Pod Identity agent caches JWT-SVIDs per audience, and a token can be up to an hour old. Lifetime from the agent is fixed at one hour. Relying parties that treat a jti as single-use, Okta being the example given, need tokens from GetWebIdentityToken through the SDK, which returns a fresh one each call.
  • Agent restarts can reissue X.509 certificates. AWS Private CA bills for each certificate issued.
  • Node setup. Nodes need IMDS hop limit 1 so pods cannot fall back to the node role. The node role needs sts:GetTrustBundles. With VPC endpoints, enable private DNS for STS and EKS Auth.

One inconsistency worth knowing. The EKS guide tells you to add sts:SetContext to the role's trust policy. The IAM guide, including its access control page, says the trust policy needs no change and no sts:SetContext statement. Both pages are in preview. I'd test against a throwaway role and see which one your account actually needs.

The quotas page lists GetWebIdentityToken at 200 requests per second per account per Region as of 2026-12-01. Limits on the number of providers or templates: not stated in the pages I read.

What this means for you

Who should care, and what to do first

If you run agents or shared-role pods on EKS, this is aimed at you. If you run a mesh and already juggle SPIRE or Istio certificate roots, it may replace some of that. If you have one small cluster and a handful of roles, you can wait.

What I'd do first:

  1. Pick one workload with a dedicated service account and a role that is shared today.
  2. Create an account-level provider, not an organisation one. Keep the blast radius small.
  3. Enable it on one association, roll the pods, and write one resource policy against the identity.
  4. Check CloudTrail shows what the docs say it should.

Verdict, as my view: adopt for a pilot, wait for GA before standardising.

What gets simpler

  • Attribution. CloudTrail puts the workload's name in userIdentity.onBehalfOf on the AssumeRole event and on later calls. The logging guide gives a CloudWatch Logs Insights query that filters on that subject and issuer. Compare that to reverse-engineering role session names.
  • Per-workload access without a role per workload. You write the rule on the resource and keep the shared role.
  • Secretless outbound auth. A JWT-SVID can replace a stored API key where the other side supports OIDC federation. The other side must be set up to trust your provider first. Nothing is accepted automatically.
  • Granting before deploy. Data owners can write the policy before the workload exists, because the name comes from facts like cluster, namespace and service account.

What gets more complex

  • More moving parts: provider, template, attestation policy, Pod Identity agent version, node role permission, and for X.509 a Private CA.
  • Naming becomes a design task. Once you customise a template, keeping names unique is on you.
  • Policy hygiene. Always pair Subject with Issuer, and use StringEquals style operators for both. The guide warns that an ARN operator on the issuer may not take effect, because issuers are not always ARNs.
  • Cross-organisation hops drop the identity. When a workload assumes a role in a different organisation, STS drops the identity keys.
  • Preview and lock-in. SPIFFE is open, but the issuer, attestation and policy keys are AWS-specific.
  • One or the other on a session. A role session carries either this or trusted identity propagation, not both.

Security notes

  • To force workloads onto the new model, the IAM guide shows a role trust policy using sts:RequestContextProviders with a Null check. Pods without an identity can then no longer use that role. That is a strong control, so roll it out after the pods are migrated.
  • Set the audience on every JWT-SVID to the one service that should accept it. The docs say this stops replay to another service.
  • Scope who can pass templates. iam:PassWorkloadIdentityTemplate is in the permission list for whoever creates the association.
  • Because identities are not stored as IAM records, CloudTrail is how you discover them. Make sure the trail, and data events if you need S3 object-level tracing, is on before you need it.

Cost

During the preview there is no charge for the identity itself on EKS or in IAM, per the launch posts and guides. Standard EKS cluster charges still apply. The one real cost driver is Private CA for X.509 certificates, and the reissue-on-agent-restart note means a rolling Pod Identity agent upgrade can add certificate issuance. I did not read the Private CA price page, so I will not put a figure on it. Price after preview: not stated.

Combining it with other services

  • S3 plus KMS: use the same aws:OriginIdentity conditions on a bucket policy and its KMS key policy, so only the one named workload can both read and decrypt.
  • Agents with outside SaaS: use the JWT-SVID for the workload's own identity. The Credential Broker, a separate IAM for agents preview, is the AWS route for reaching external systems such as Snowflake and Databricks through your identity provider. They answer different questions.
  • AgentCore: Runtime and Gateway can also attest and deliver identity. Gateway gets JWT-SVIDs only, per the IAM guide.

Other angles

I have not read an Azure or GCP comparison on the sources I used, so I will not draw one. What I will say: if you already run SPIRE, check what this covers before you switch. The EKS guide says it gives workloads a SPIFFE identity without requiring you to operate the underlying identity infrastructure yourself, which is the pitch.

Next step: pick the workload today, and list which of your outside integrations accept OIDC federation. That list tells you how much of the secret clean-up this can really do.

Related posts

Sources

Drafted with AI assistance. I review and edit every post.

原文:https://www.a8q9.cn/en/article/iam-agent-and-workload-identity-on-eks-per-pod-spiffe-names-preview-limits-a76433.html

相关文章