Tenancy and software supply chains
Combine tenant boundaries with image verification and trace how a cluster enforces each control.
What you will understand
- Explain what a namespace scopes and what requires additional isolation controls.
- Explain how a tag, digest, signature, and provenance answer different questions.
- Verify a tenant’s API permissions, network behavior, and image admission independently.
Builds on: Metrics, logs, and traces, GitOps and drift reconciliation
Choose how to isolate tenants
Two teams share a cluster. Each should manage its own apps. One team also wants to ensure that only builds from its approved pipeline reach production. A namespace scopes objects such as Pods and Roles. It gives you a place to apply namespaced access rules and resource budgets. Tenant isolation also needs to cover network traffic, privileged workloads, cluster-scoped configuration, and the degree of trust teams place in the same nodes and control plane.
In the tenant scene, try an API request, a network connection, and a privileged Pod proposal. RBAC, network policy enforcement, and admission each answer a different part of the question. A quota limits use of a shared resource. Stronger isolation requirements may call for separate nodes, control planes, or clusters, depending on the threat model.
Where are shared-cluster boundaries enforced?
Namespace policies scope access and traffic. Cluster-wide resources and shared hosts require separate trust and isolation decisions.
Scope API access
- Tenant identityRBAC + admissionrequest access
- RBAC + admissionNamespaceallowed resources
A namespace groups resources but does not itself grant or deny every operation.
Enforce independent runtime and network controls
- RBAC + admissionAllowed operations and workloads
- NamespaceNetwork enforcementapply traffic policy
RBAC, admission, quotas and network implementation supply distinct restrictions.
Evaluate the shared-node boundary
- NamespaceShared node / kernelworkloads share infrastructure
Privileged workloads and shared kernels affect tenant separation beyond namespace names.
The appropriate isolation strength depends on whether tenants are cooperative teams or mutually untrusted actors.
Explore another case
Verify who built a pinned image
An image tag is a human-readable name that can be moved. A digest identifies particular image manifest contents or an image index. Pinning by digest protects against silently pulling different bytes when the tag moves. A signature can tie the artifact to a signer trusted by your policy, and provenance can record which source and build process produced it. A verification policy can require specific identities or build conditions, then accept or reject a workload at admission. Test these distinctions in the artifact scene.
How can admission check an image’s origin?
A digest identifies the artifact. Signatures and provenance provide evidence that a verification policy can require before allowing it.
Identify the image digest
- Build pipelineRegistry digestpublish content
- Build pipelineSignature / provenancepublish evidence
A digest selects content rather than a mutable tag, but does not state that the content is approved.
Verify signature and provenance
- Registry digestAdmission verifierdigest to verify
- Signature / provenanceAdmission verifieridentity and claims
A verifier checks signatures and required claims against explicit approved identity and trust roots.
Enforce the result at admission
- Admission verifierAdmitted Podpolicy permits
Only an installed configured mechanism makes verification part of Pod admission; signatures do not enforce themselves.
The lab does not provide a signed production image or install a verifier; this models the explicit enforcement contract.
Explore another case
Test each enforcement layer
This optional NetworkPolicy isolates selected Pods in both directions without adding any allow rules. It only takes effect with supporting network enforcement, and other policies can still permit traffic. Apply it to a labeled disposable Pod and compare a fresh connection before and after. Then use a tenant identity to inspect an intended grant and an action it should lack. The registry command shows the manifest information for a training image. It does not verify a signature or assert a provenance policy.
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: m19-isolate
namespace: kv-lab
labels:
lab: m19
spec:
podSelector:
matchLabels:
tenant-experiment: isolated
policyTypes: [Ingress, Egress]
ingress: []
egress: []kubectl --context kind-kv-lab auth can-i create clusterrolebindings
kubectl --context kind-kv-lab -n kv-lab get roles,rolebindings,resourcequotas,networkpolicies
# Read the actual registry manifest information; do not invent a digest.
docker buildx imagetools inspect nginx:1.28.0-alpine
# Remove the optional policy after its isolated experiment.
kubectl --context kind-kv-lab -n kv-lab delete networkpolicy m19-isolate --ignore-not-foundUse the platform operations lab for the permissions and drift baseline. Test network blocking or image signature enforcement only in an environment configured for those controls.
Check what the tenant is actually allowed to do
Broad rights to create privileged Pods or change cluster-scoped bindings can undermine tenant boundaries. Test permissions with the actual tenant identity, not a cluster administrator. Even an image with an approved signature can contain defects. Maintain the checks relevant to the threat, such as reviewing build provenance, scanning the artifact, and restricting runtime access.
Check your understanding
The image is pinned by digest. How would you show that your approved pipeline produced it?
Verify a signature and associated provenance for that digest against the trusted pipeline identity and build rules. The digest gives you a stable artifact identity to verify. The attestation supplies evidence about its origin.
Go to the source
- Kubernetes multi-tenancy
- Container image names and digests
- Sigstore signature verification
- NetworkPolicy
Reviewed 2026-10-27 · Kubernetes 1.37 · Related local exercise