Skip to content

Workload Identity Federation

Workload Identity is the “Sovereign Handshake” for the non-human actors in your ecosystem. In a cloud-native world, services, containers, and serverless functions (Workloads) must authenticate to each other without static, long-lived “Secrets” or “API Keys” which are easily leaked. Workload Identity Federation allows services to use Short-Lived, Cryptographically Verifiable Tokens issued by a trusted identity provider (like AWS IAM, Entra ID, or SPIFFE) to gain access to resources. For the IAM architect, Workload Identity is the engine of Secretless Infrastructure, enabling a Zero Trust posture where every machine process has a verifiable and ephemeral digital persona.

WORKLOAD ID

Machine Sovereign
Core Mission
Secretless Machine Orchestration. Establishing a rigorous, token-based framework for machine identity that eliminates the need for static credentials and ensures every service-to-service interaction is authenticated and authorized in real-time.
Like a Corporate ID for an Automated Robot: Imagine your office is full of automated delivery robots (Your Services). Traditionally, you gave each robot a "Physical Key" (A Static API Key) to open doors. If a robot was stolen, the key worked forever. Workload Identity is like giving the robot a "Digital Scanner." When the robot reaches a door, it proves its identity to the "Sovereign Controller" (The IdP), which gives it a "Temporary QR Code" (A Short-lived Token). The robot uses that code to enter the room. The code expires in 5 minutes, and if the robot is compromised, it has no permanent key to steal.
Kubernetes-to-Cloud Auth / GitHub Actions Secretless Auth / Cross-Cloud API Access / Microservices mTLS

Designing for machine identity requires understanding the trust relationship between the workload, its platform, and the resource.

PillarStrategic ResponsibilityIAM Implementation
Trust RelationshipThe Foundation.Defining which external IdP (e.g. GitHub, K8s) is authorized to issue tokens for your cloud roles.
AttestationThe Proof.The process by which a workload proves its “Health” and “Identity” to its platform (e.g., TPM, K8s ServiceAccount).
Token ExchangeThe Bridge.Exchanging a platform-specific token (OIDC) for a cloud-specific access token (e.g., AWS STS).
Least Privilege BoundThe Limit.Strictly limiting the scopes and resources a machine identity can access.

Authenticating a machine follows a “Prove-Exchange-Authorize” path designed for ephemerality.

graph LR
    Workload[Workload: Request Access] --> Attest[Platform: Issue OIDC Token]
    Attest --> Exchange[Cloud IdP: Verify & Exchange]
    Exchange --> Token[Resource: Grant Access via JWT]
1

Platform Attestation

The workload (e.g., a pod in Kubernetes) requests an identity token from its host platform. The platform verifies the "Attestation" of the workload—checking its ServiceAccount, Namespace, and even the cryptographic integrity of the container. It issues a signed **OIDC ID Token** specifically for that process.

2

The Federated Exchange

The workload presents this OIDC token to the **Cloud Identity Provider** (e.g., AWS STS or Entra ID). The Cloud IdP verifies the signature against the platform's public OIDC discovery endpoint. If the "Trust Relationship" exists and the token claims match (e.g., "Must be from Production Namespace"), the Cloud IdP performs the "Sovereign Exchange."

3

Resource Authorization

The Cloud IdP issues a short-lived **Access Token** (or temporary credentials). The workload uses this token to call the target resource (e.g., an S3 bucket or a Database). The resource validates the token and grants access. No static secrets were ever stored in the code or environment—identity was established via current, verifiable proof.


Configuring GitHub Actions to use Workload Identity (OIDC) to access AWS is the gold standard for secure CI/CD.

# Creating an OIDC Provider for GitHub Actions
resource "aws_iam_openid_connect_provider" "github" {
url = "https://token.actions.githubusercontent.com"
client_id_list = ["sts.amazonaws.com"]
thumbprint_list = ["6938fd4d98bab03faadb97b34396831e3780aea1"] # GitHub's CA
}
# Role that GitHub Actions can assume
resource "aws_iam_role" "github_actions_role" {
assume_role_policy = jsonencode({
Version = "2012-10-17"
Statement = [{
Action = "sts:AssumeRoleWithWebIdentity"
Effect = "Allow"
Principal = { Federated = aws_iam_openid_connect_provider.github.arn }
Condition = {
StringLike = { "token.actions.githubusercontent.com:sub": "repo:sovereign-org/*" }
}
}]
})
}

Master the technical ceremonies of machine-to-machine trust and secretless infrastructure.