CWE
78
Advisory Published
Updated

CVE-2021-41254: Privilege escalation to cluster admin on multi-tenant environments

First published: Fri Nov 12 2021(Updated: )

kustomize-controller is a Kubernetes operator, specialized in running continuous delivery pipelines for infrastructure and workloads defined with Kubernetes manifests and assembled with Kustomize. Users that can create Kubernetes Secrets, Service Accounts and Flux Kustomization objects, could execute commands inside the kustomize-controller container by embedding a shell script in a Kubernetes Secret. This can be used to run `kubectl` commands under the Service Account of kustomize-controller, thus allowing an authenticated Kubernetes user to gain cluster admin privileges. In affected versions multitenant environments where non-admin users have permissions to create Flux Kustomization objects are affected by this issue. This vulnerability was fixed in kustomize-controller v0.15.0 (included in flux2 v0.18.0) released on 2021-10-08. Starting with v0.15, the kustomize-controller no longer executes shell commands on the container OS and the `kubectl` binary has been removed from the container image. To prevent the creation of Kubernetes Service Accounts with `secrets` in namespaces owned by tenants, a Kubernetes validation webhook such as Gatekeeper OPA or Kyverno can be used.

Credit: security-advisories@github.com

Affected SoftwareAffected VersionHow to fix
Fluxcd Kustomize-controller<0.15.0

Never miss a vulnerability like this again

Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.

Frequently Asked Questions

  • What is CVE-2021-41254?

    CVE-2021-41254 is a vulnerability in kustomize-controller, a Kubernetes operator that runs continuous delivery pipelines for infrastructure and workloads defined with Kubernetes manifests and assembled with Kustomize.

  • What is the severity of CVE-2021-41254?

    CVE-2021-41254 has a severity rating of 8.8 (Critical).

  • Who is affected by CVE-2021-41254?

    Users of Fluxcd Kustomize-controller version up to exclusive 0.15.0 are affected.

  • What is the CWE of CVE-2021-41254?

    CVE-2021-41254 is classified under CWE-78 (Improper Neutralization of Special Elements used in an OS Command).

  • How can CVE-2021-41254 be fixed?

    To fix CVE-2021-41254, users should upgrade to a fixed version of Fluxcd Kustomize-controller.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2024 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203