Enterprise AI, cloud modernization, cybersecurity and platform engineering.
Resources › Guide

Kubernetes security for banks and other regulated firms

iNET SYSTEMS DevOps Practice • Published • Last updated • 2 min read
Reviewed by iNET SYSTEMS Architecture Practice

Why regulated containers face bigger risks

Containers at banks and government agencies face far more risk than those at a typical startup. Banks and fintechs answer to Federal Financial Institutions Examination Council (FFIEC) guidance and National Institute of Standards and Technology (NIST) rules. For them, a container that breaks out of its limits, a user who gains extra rights, traffic between pods sent in plain text or a tainted base image can do serious harm.

To run Kubernetes safely in a regulated firm, you need layers of defense at every stage. Check where each base image came from. Block bad settings before a pod starts. Then watch what each container does while it runs, with eBPF.

Block unsafe pods before they start

The first defense is to reject a bad or unsafe pod before it reaches a node. Tools such as Kyverno or Open Policy Agent (OPA) Gatekeeper do this. They apply the Kubernetes restricted Pod Security Standard to every live namespace. The policy below blocks pods that run as root or that can write to their own file system:

# Kyverno Policy: Disallow Root Containers & Enforce Read-Only Root Filesystem
apiVersion: kyverno.io/v1
kind: ClusterPolicy
metadata:
  name: enforce-pod-hardening
spec:
  validationFailureAction: Enforce
  rules:
    - name: check-security-context
      match:
        resources:
          kinds:
            - Pod
      validate:
        message: "Running as root or writeable root filesystem is strictly prohibited!"
        pattern:
          spec:
            securityContext:
              runAsNonRoot: true
            containers:
              - securityContext:
                  allowPrivilegeEscalation: false
                  readOnlyRootFilesystem: true
                  capabilities:
                    drop:
                      - ALL

Zero Trust between pods with Cilium and eBPF

Cilium is a network plugin for Kubernetes. It filters traffic inside the Linux kernel with eBPF, which gives you three strong controls:

  • Rules at the application programming interface (API) level: Limit which pods may talk, not just by address or port, but by the web method and path they call.
  • Encryption between nodes: All traffic between pods on different nodes is encrypted on its own, with WireGuard or Internet Protocol Security (IPsec).
  • Deny by default: Each namespace starts with a rule that blocks all traffic. Pods can only talk when a written policy allows it.

Where to start

Start with the admission policy above, since it stops the most common mistakes. Then add default-deny network rules, one namespace at a time. Last, add image signing and runtime checks. Each step can be tested on its own, so you never need one big, risky change.

Questions about this article

How do you block unsafe pods?

Use an admission controller such as Kyverno or OPA Gatekeeper to apply the Kubernetes restricted Pod Security Standard to every live namespace.

What does Cilium add to Kubernetes security?

It filters traffic in the Linux kernel with eBPF, giving API-level rules, encryption between nodes with WireGuard or IPsec, and deny-by-default namespaces.

Where should a regulated firm start?

Start with the admission policy, then add default-deny network rules one namespace at a time, and finally image signing and runtime checks.

Related service

Kubernetes Consulting for AKS, EKS and GKE

Kubernetes consulting for Azure Kubernetes Service (AKS), Amazon Elastic Kubernetes Service (EKS) and Google Kubernetes Engine (GKE): cluster design, network isolation, GitOps, secrets, observability and production operations.

Explore Kubernetes Consulting for AKS, EKS and GKE

Further reading

Source and what it covers
Kubernetes security concepts
Kubernetes. Security concepts for Kubernetes clusters and workloads.
CIS Kubernetes Benchmark
Center for Internet Security. Configuration benchmarks for securing Kubernetes clusters.
What is Azure Kubernetes Service (AKS)?
Microsoft. Microsoft's managed Kubernetes service on Azure.
Talk to us

Want help putting this to work?

We can help you turn these steps into a plan that fits your team.

New to iNET SYSTEMS? Meet our founder, see how we work, read the FAQs or start with an AI Security Readiness Assessment.

Book a 30-minute Call
Contact us