Cluster Policy Examples for Containers
apiVersion: security.kubearmor.com/v1 kind: KubeArmorClusterPolicy metadata: name: csp-in-operator-block-process spec: severity: 8 selector: matchExpressions: - key: namespace operator: In values: - nginx1 process: matchPaths: - path: /usr/bin/apt action: BlockapiVersion: security.kubearmor.com/v1 kind: KubeArmorClusterPolicy metadata: name: csp-in-operator-block-process spec: severity: 8 selector: matchExpressions: - key: namespace operator: NotIn values: - nginx1 process: matchPaths: - path: /usr/bin/apt action: BlockapiVersion: security.kubearmor.com/v1 kind: KubeArmorClusterPolicy metadata: name: csp-matchlabels-in-block-process spec: severity: 8 selector: matchExpressions: - key: namespace operator: In values: - nginx1 - key: label operator: In values: - app=nginx - app=nginx-dev process: matchPaths: - path: /usr/bin/apt action: BlockapiVersion: security.kubearmor.com/v1 kind: KubeArmorClusterPolicy metadata: name: csp-matchlabels-not-in-block-process spec: severity: 8 selector: matchExpressions: - key: namespace operator: NotIn values: - nginx2 - key: label operator: NotIn values: - app=nginx process: matchPaths: - path: /usr/bin/apt action: Block
apiVersion: security.kubearmor.com/v1 kind: KubeArmorClusterPolicy metadata: name: csp-in-operator-block-file-access spec: severity: 8 selector: matchExpressions: - key: namespace operator: NotIn values: - nginx2 file: matchPaths: - path: /etc/host.conf fromSource: - path: /usr/bin/cat action: Block
Last updated
Was this helpful?