From the course: Certified Kubernetes Security Specialist (CKS) Cert Prep

Unlock this course with a free trial

Join today to access over 25,300 courses taught by industry experts.

Finding open ports

Finding open ports

- Controlling access to Kubernetes means being able to manage all the various open ports that you might have on the system. Now this is very similar to what you do when you're protecting your home. You're looking for all the doors, the windows, you want to make sure things are closed that are supposed to be closed, and that you have the ability to be able to open certain aspects of it to kind of control the flow. Same concepts here, when we're dealing with Kubernetes. And to do that, there's a number of different commands that we can use. The first is the ss command. The ss command is a replacement for netstat. It's very similar, as far as the command line flags, and all the various components that you're familiar with, with netstat, but it's a little bit easier to read and it's the more modern way of being able to get this information. So this particular one, again, will give you that list of open ports. To be able to find what services and user accounts are tied to those open ports,…

Contents