concourse-chart icon indicating copy to clipboard operation
concourse-chart copied to clipboard

harden the security even if worker pod with privileged: true

Open gowrisankar22 opened this issue 5 years ago • 3 comments

We are allowing privileged: true for the worker pod to allow the task to run in a container. This will be security problem and described here https://concourse-ci.org/task-step.html#task-step-privileged. how can we make sure the security even if it is enabled?

https://github.com/concourse/concourse-chart/blob/c13f1427bf0d484dad35ee73ffcdec5d19acb7c5/templates/worker-statefulset.yaml#L59

gowrisankar22 avatar Jan 24 '20 14:01 gowrisankar22

Currently the best way to ensure that workloads on your Concourse workers are isolated is to have one k8s cluster dedicated to running Concourse. Work is being done to move away from rootless workers being required (https://github.com/concourse/concourse/issues/5073). In the meantime, you should network off (whitelist access to specific network endpoints only) Concourse workers as much as possible and restrict their access as much as possible if security is of the utmost concern to you.

Regarding the task privileged field, something like OPA RFC would help address this by allowing a Concourse operator to disallow users from creating privileged tasks.

taylorsilva avatar Feb 03 '20 15:02 taylorsilva

thanks a lot @taylorsilva what would be the tentative timeline for rootless workers and opa?

gowrisankar22 avatar Feb 04 '20 03:02 gowrisankar22

No idea! OPA is being done by someone outside our team and we're working on getting containerd working with our existing use-cases first.

taylorsilva avatar Mar 26 '20 13:03 taylorsilva