Description
Omit hostIPC or set it to false unless a system workload needs the node’s shared memory or semaphores.
Potential impact
A Pod with hostIPC: true shares the node’s IPC namespace. Its processes may read or alter host IPC data where resource permissions allow it.
Remediation
Check the deployed Pod’s execution user and IPC permissions. Limit exceptions to workloads that need them and enforce namespace restrictions with Pod Security Admission or a policy engine.
Examples
Before
yaml
apiVersion: v1
kind: Pod
metadata:
name: security-context-demo
spec:
hostIPC: true
containers:
- name: sec-ctx-demo
image: busybox
After
yaml
apiVersion: v1
kind: Pod
metadata:
name: security-context-demo
spec:
hostIPC: false
containers:
- name: sec-ctx-demo
image: busybox
To apply hostIPC: false, roll out new Pods from the updated workload template or replace a standalone Pod. Check network and process sharing separately in hostNetwork and hostPID.