CertGrid CertGrid
Hands-on Lab·Kubernetes and Cloud Native Security Associate

Attacker Persistence Mechanisms

Getting in is one problem; staying in is a different one, and in Kubernetes it is solved with ordinary objects that look like configuration. This guide plants three of them, shows why each survives a reboot, and ends with the one query that finds the first.

Kubernetes Threat Model Guide 30 of 42 Intermediate

Written against the versions above. Manually created `kubernetes.io/service-account-token` Secrets are still populated by the token controller in v1.36 and the JWT they contain carries no `exp`. Auto-creation of these Secrets ended in 1.24; creating one by hand did not.

The cka5001 cluster: one control plane and 3 schedulable workers, on Cilium.
Server NameIP AddressOSRolesCPURAMHDD
CKA5001192.168.0.41Ubuntu 26.04 LTSControl Plane Node (tainted NoSchedule)2 Core4 GB50 GB
CKA5001-NODE01192.168.0.42Ubuntu 26.04 LTSWorker Node2 Core4 GB50 GB
CKA5001-NODE02192.168.0.43Ubuntu 26.04 LTSWorker Node2 Core4 GB50 GB
CKA5001-NODE03192.168.0.44Ubuntu 26.04 LTSWorker Node2 Core4 GB50 GB

Before you start

  1. A backdoor that is one object

  2. A credential that does not expire

  3. For contrast, the modern token

  4. A beacon that is not a running process

  5. The query that finds the first one

Official sources