private cluster· workload identity· tamper-evident ledger· terraform + bicep

azure · aks · platform engineering

A zero-trust AKS platform, and a database that catches its own tampering.

A private Azure Kubernetes cluster with no public API server, no static credentials anywhere, and a payments-style audit table on Azure SQL Ledger that cryptographically proves whether its own history has been altered. Built as a hands-on demonstration of zero-trust platform design — from cluster access to pod identity to policy enforcement to the audit trail itself.

zero-trust-aks — live checks
$ kubectl run bad-pod --image=nginx --dry-run=server
Error from server: admission webhook denied the request:
container <bad-pod> uses image <nginx>, which resolves to
the :latest tag — pin an explicit version

$ EXEC sys.sp_verify_database_ledger @corrupted_digest
Msg 37339, Level 16, State 5
The hash of block 0 in the database ledger doesn't
match the hash provided in the digest for this block.

$ az aks command invoke --command "kubectl get nodes"
NAME                      STATUS   ROLES
aks-system-12345678-0     Ready    <none>
aks-system-12345678-1     Ready    <none>

architecture

How it's put together

One VNet, a private AKS cluster, and three PaaS services — SQL, Storage, Key Vault — each reachable only through a Private Endpoint. Nothing in this diagram has a public IP.

Add your architecture diagram here Export the diagram from the README (or redraw it in Excalidraw / draw.io) as a PNG or SVG and swap it in for this box — <img src="architecture.png" alt="Architecture diagram">. Recommended size: ~1400px wide, dark background to match the page.

what this proves

Four things a private cluster doesn't give you for free

Each of these is a real gap between "the setting is enabled" and "the thing actually works day-to-day" — and how it's closed here.

01

Reaching a cluster with no public API server

az aks command invoke, from Codespaces
02

Pods talking to Azure services with no stored secrets

Azure AD Workload Identity, federated OIDC
03

Enforcing pod security without waiting on Microsoft's catalog

Azure Policy (built-in) + a custom Gatekeeper rule
04

An audit log that proves — not just claims — it's untampered

Azure SQL Ledger, digest verification

the centerpiece

Watch it catch tampering

The ledger table rejects direct edits to its own history outright. For the harder case — data altered below the database engine — a digest verification later proves exactly which block stopped matching. Both are reproducible from the scripts in the repo.

Add a screen recording of the demo here A 20–40s clip (or a few screenshots) running sql/05_engine_level_tamper_attempt.sql and sql/06_verify_with_corrupted_digest.sql and showing the resulting errors is the single most convincing thing on this page — swap this box for a <video> or an animated GIF.

posture

What "zero-trust" means concretely, here

No public API serverPrivate cluster — not IP-restricted, genuinely absent from the internet

No static cluster credentialsLocal accounts disabled; access is Entra ID or ARM-mediated only

No public data-plane endpointsSQL, Storage, and Key Vault reachable only via Private Endpoint

No long-lived pod secretsWorkload Identity issues short-lived, auto-rotated tokens

No un-pinned container imagesPolicy-enforced allowed registries, resource limits, no :latest

Tamper-evident, not just tamper-loggedSQL Ledger detects — with proof — not just records

built with

Terraform Bicep Azure Kubernetes Service Azure SQL Ledger Azure AD Workload Identity Azure Policy · Gatekeeper Helm GitLab CI/CD