# AKS Workload Identity Manifest Checker

> Checks Kubernetes manifests for AKS workload identity wiring: ServiceAccount client-id annotations, the pod use label, serviceAccountName, leftover client secrets and retired AAD Pod Identity labels. Offline and read-only.

AKS Workload Identity Manifest Checker is a paid AI agent skill on Agensi by Abdelrhman Fikri, in DevOps & Cloud. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: $9.99 (one-time purchase)
- Creator: [Abdelrhman Fikri](https://www.agensi.io/creators/abdelrhman-fikri)
- Category: [DevOps & Cloud](https://www.agensi.io/skills/devops-cloud)
- Version: 1.0.0
- Last updated: 2026-12-03
- Security: scan passed (2026-12-03); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/aks-workload-identity-manifest-checker
- Tags: aks, kubernetes, workload-identity, entra, security, devops, serviceaccount, gitops

## What it does

- Scans Kubernetes YAML and JSON for ServiceAccounts and workload pod templates
- Checks that a workload-identity pod sets serviceAccountName and the use label
- Verifies the ServiceAccount (or pod) carries the client-id annotation
- Flags leftover AZURE_CLIENT_SECRET, credential secret mounts and disabled token automount
- Warns about misplaced labels, non-UUID client ids and retired AAD Pod Identity bindings

## Who it's for

- **Platform and application engineers on AKS:** who are adopting workload identity, migrating off service-principal secrets or AAD Pod Identity, or reviewing a GitOps pull request.

## About this skill

A pod that is "almost" wired for AKS workload identity still fails at runtime: the webhook only mutates pods that carry the use label, the token is projected from the ServiceAccount you name, and a leftover client secret quietly wins in the Azure SDK. This skill gives your agent a deterministic, offline workflow over the manifests in git.

The scanner is a single standard-library script. It does not call the cluster or Entra. It reads Deployments, StatefulSets, DaemonSets, Jobs, CronJobs, Pods and ServiceAccounts, including across files in the same scan. It reports blockers when the use label is set but serviceAccountName is missing, when a client-id annotation has no matching use label, when automount of the service-account token is disabled, and when a container still injects AZURE_CLIENT_SECRET or mounts a credential secret. Warnings cover labels or annotations on the wrong object, a client-id that is not a UUID, a ServiceAccount that was not in the scan set, and the retired AAD Pod Identity label.

Synthetic example manifests with expected output are included so you can verify the behaviour in seconds.

## Known limitations

- File-based only: it cannot see the cluster, the OIDC issuer, or the federated credential on the Entra application.
- YAML support is a subset parser for typical manifests. It does not evaluate Helm conditionals; scan helm template output for exact results. Anchors and unusual flow style may produce a parse warning.
- If a manifest has no namespace, ServiceAccount matching assumes `default`.
- Reports and explains; it does not rewrite your manifests or create federated credentials.

## Technical details

The scanner is a single standard-library Python script. It makes no network calls and never writes files or talks to a cluster. Give it files or directories; it walks .yaml, .yml and .json.

YAML is parsed with a built-in subset parser for typical Kubernetes manifests (block mappings and sequences, quoted scalars, comments, multi-document files). JSON lists, single objects and List items are accepted. Helm is not evaluated; scan rendered output.

It indexes ServiceAccount objects by namespace and name, then inspects Pod, Deployment, StatefulSet, DaemonSet, Job, ReplicaSet, ReplicationController and CronJob pod templates (including CronJob jobTemplate). Cross-file references in the same scan set are resolved.

Exit codes: 0 no blockers, 1 blockers found, 2 bad arguments. Optional --format json.

It cannot see the cluster OIDC issuer or the Entra federated credential.

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the AKS Workload Identity Manifest Checker skill from Agensi" and describe your task.
3. Buy it on the listing or let your agent ask you first; your agent then loads it from Agensi when it needs it. Every paid skill has a money-back guarantee: https://www.agensi.io/docs/money-back-guarantee

## Frequently asked questions

### Does it need cluster access?

No. It only reads the files you point it at.

### Can it tell me if the federated credential is correct?

No. That lives on the Entra application. This skill only checks the manifest wiring.

### Which Python?

Python 3.9 or newer, no packages to install.

### Does it understand CronJobs?

Yes. It looks at spec.jobTemplate.spec.template, the same way it looks at spec.template on a Deployment.

### What does exit code 1 mean?

One or more BLOCKER findings. Warnings alone still exit 0.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
