<img src="https://ws.zoominfo.com/pixel/JHVDdRXH2uangmUMQBZd" width="1" height="1" style="display: none;">

Magalix Introduces the Cloud-Native Application Policy Pack

Exit icon Learn More

Pod Security Policies Advisor - Container Running as Root

DevOps Kubernetes Governance Policies
Pod Security Policies Advisor - Container Running as Root
DevOps Kubernetes Governance Policies

OVERVIEW

By default, containers run as root. We consider this a security risk and something overlooked in many cases.

How Magalix Helps

Magalix KubeAdvisor ships with a governance policy that detects all your containers running as root across all of your Kuberentes clusters. We ship this policy enabled by default and consider this one of our best practice policies due to the level of access it gives to your running container.

Identifying the Issue

Issues Dashboard

When logging into the Magalix console, find your cluster and drill down to Issues using the navigation bar on the left.

Pod Security Policies Advisor - Container Running as Root

You’ll be brought to your Issues Dashboard. The top half of the page will contain information and graphs displaying the total number of violations against the total number of governance policies, or as we call them, Advisors. In the lower half of the page, locate Container running as root.

Issue Page

If you click on the issue, you can see an overview of how many entities are out of compliance along with a description of the Advisor.Pod Security Policies Advisor - Container Running as RootTowards the lower portion of the page, you will see each individual violation. After clicking on an entity, you can see the full breakdown in our Recommendation page.

Recommendation Page

Pod Security Policies Advisor - Container Running as Root

1- Description

In every policy, we give a brief explanation of our policy.

2- Evidence

As a part of the violation, Magalix KubeAdvisor shows you your entity in YAML format. You can identify exactly where the problem is. In this case, you can search for securityContext and examine whether or not runAsNonRoot is set.

3- Resolution

This area provides suggestions on how you can resolve the violation.

4- History

At the bottom, we also show you how long this entity has been in violation, giving you some insight into whether or not any new issues are a result of this violation.

Conclusion

Docker containers run as root by default. Kubernetes allows you to set which user you’d like to run as. In combination with understanding the users available in your container and by setting the container to run as that user, you can be sure that you have at least one security safeguard in place to protect your most important digital assets.

Identify Containers Running as Root in Your Clusters Now

Comments and Responses

Related Articles

7 Notable and Costly Security Breaches

Learn some notable security breaches that happened a few years ago, the root causes, and how Magalix can help protect your Kubernetes infrastructure

Read more
Security Context Settings Help Mitigate Kubernetes Risk

Kubernetes isn't secure by default and is attacked relentlessly. But security context settings help DevOps teams better secure their pods and containers.

Read more
DevOps Policy as Code
Cloud Data Asset Management and Tagging Cloud Resources

Learn how cloud data asset management enables organizations to manage, optimize and secure their cloud data assets and resource tagging is a key part of it

Read more