← ClaudeAtlas

auditing-init-and-sidecar-injection-trustlisted

Audit the init and sidecar containers a workload runs, including ones injected by a mutating admission webhook, for trust the main container never granted: an injected sidecar that runs with broader privileges, host access, or credentials than the workload, an init container that fetches and executes remote content before the app starts, a shared volume or process namespace that lets a sidecar read the main container's secrets, and an injection whose image and configuration come from a source the workload owner does not control. Covers Kubernetes pods where init and sidecar containers, declared or webhook-injected, share the pod with the application. Use when pods run init or sidecar containers, especially injected ones. The injected or auxiliary container is the source, the pod resource or credential it reaches is the sink, and the trust it holds beyond the main container is the bug.
UnboundCompute/security-agent-skills · ★ 4 · AI & Automation · score 80
Install: claude install-skill UnboundCompute/security-agent-skills
# Auditing init and sidecar injection trust: the containers you did not write share your pod A pod is not just its application container. Init containers run first, sidecars run alongside, and many are injected automatically by a mutating admission webhook that the workload owner never sees in their manifest. All of them share the pod: the same network namespace, often shared volumes, sometimes the process namespace, and they can be granted their own security context and credentials. That makes every init and sidecar container a trust question the main container did not ask. An injected sidecar may run privileged or with host access the app never needed; an init container may fetch and execute remote content before the app starts; a shared secret volume or process namespace lets a sidecar read the application's secrets; and the injected image and its configuration may come from a source outside the workload owner's control. The pod looks like one workload but is a collection of containers with different privileges and origins. You audit this by enumerating every init and sidecar container, declared and injected, and checking what trust each holds. ## When to use - Pods run init or sidecar containers, especially ones injected by a mutating admission webhook. - An injected or auxiliary container may run with broader privilege, host access, or credentials than the app. - Init containers fetch or execute content, or sidecars share volumes or namespaces with the main container.