A Container in Prod Is Mining Crypto

A pod is pegging CPU running a crypto miner. A teammate wants to kubectl delete it and move on. Defend the real response.

advanced15 min5 roundsKubernetesSecurity

Answer key reviewed by Branko Petric

Read first: Kubernetes RBAC and Security

Your decision

You discover a pod in your production cluster is running a crypto miner and making outbound connections to an unknown host. A teammate says just kubectl delete the pod and we are done. How do you actually respond?

The situation

Monitoring flags a pod pinning CPU. You exec in and find a crypto miner running, with steady outbound connections to an IP you do not recognize.

Context

The pod runs a public-facing service and has a mounted service account token and access to a few secrets. You do not yet know how it was compromised. A teammate wants to simply kubectl delete the pod so CPU returns to normal and the alert clears.

More: Kubernetes scenario interview questions