Giter VIP home page Giter VIP logo

Comments (2)

lojikil avatar lojikil commented on May 29, 2024

I think there's a cert pinning finding here too... reading through the docs, we get this:

Trusting the cluster root CA from an application running as a pod usually requires some extra application configuration. You will need to add the CA certificate bundle to the list of CA certificates that the TLS client or server trusts. For example, you would do this with a golang TLS config by parsing the certificate chain and adding the parsed certificates to the RootCAs field in the tls.Config struct.

So, there's likely to be certain portions of keys in the PKI that aren't within the known certs and can't be verified; likewise, there isn't really cert pinning or the like for components, and bundles are copied over. Therefore, attackers who can request certs, attackers who can modify the bundle, &c. could all attack the above that Dominik pointed out. Clearly they need to have some level of self-signed certs (for the root), but if they're copying over the bundles they can pretend to have a real PKI with CA/IA, so why InsecureSkipVerify and not cert pin (or at least TOFU ala HSTS/HPKP).

So, how do they fix:

  1. Don't use InsecureSkipVerify, instead head in the direction that kubeadm is going and download certs as part of the install
  2. Use an actual PKI: if the Root CA is to be the cluster CA then make it the cluster CA and have an actual process for handling certs via the same
  3. Use Cert Pinning, HSTS, HPKP, TOFU, whatever, and enforce it for critical components like the API server and kube-proxy
  4. Implement OCSP Stapling to minimize contact with root CA

@tomsteele @btonic @disconnect3d thoughts?

from audit-kubernetes.

lojikil avatar lojikil commented on May 29, 2024

TOA-K8S-013

from audit-kubernetes.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.