{"id":4971,"date":"2020-04-22T08:00:32","date_gmt":"2020-04-22T02:30:32","guid":{"rendered":"https:\/\/www.upnxtblog.com\/?p=4971"},"modified":"2020-07-06T12:20:01","modified_gmt":"2020-07-06T06:50:01","slug":"do-you-inspect-your-containers","status":"publish","type":"post","link":"https:\/\/www.upnxtblog.com\/index.php\/2020\/04\/22\/do-you-inspect-your-containers\/","title":{"rendered":"Do you inspect your containers?"},"content":{"rendered":"<div class='booster-block booster-read-block'><\/div><p>With the increasing <a href=\"https:\/\/www.upnxtblog.com\/index.php\/2020\/03\/09\/9-key-takeaways-from-cncf-survey-2020\/\">adoption <\/a>of containers and <a href=\"https:\/\/www.upnxtblog.com\/index.php\/2017\/12\/11\/top-20-microservices-design-patterns\/\">microservices<\/a> in the enterprises, there are also risks that come along with containers. For example, If any one of the containers breaks out, it can allow unauthorized access across containers, hosts, or data centers, etc., thus affecting all the containers hosted on the Host OS. To mitigate these risks, we have already looked at <a href=\"https:\/\/www.upnxtblog.com\/index.php\/2019\/01\/04\/implementing-secure-containers-using-gvisordocker-tutorial\/\">various approaches<\/a> to provide secure isolation for containers. In this post, we are going to look at how to inspect the containers.<\/p>\n\n<h2>Introducing\u00a0 amicontained<\/h2>\n<p>Using <strong><a href=\"https:\/\/github.com\/genuinetools\/amicontained\" target=\"_blank\" rel=\"noopener\">amicontained<\/a> <\/strong>tool, we can find out what container runtime, other data points like below:<\/p>\n<ol>\n<li>What <strong>data does the container have access to<\/strong>?<\/li>\n<li>What is the <strong>composition of your containers during runtime<\/strong>?<\/li>\n<li>What type of <strong>system calls is being blocked<\/strong>?<\/li>\n<li>What are the details of the <strong>SECCOMP\/AppArmor profile<\/strong> that is being used to prevent attacks and preventing others from spreading to the rest of the infrastructure?<\/li>\n<\/ol>\n<h2>#1. Install amicontained<\/h2>\n<p>Install binaries are available from <a href=\"https:\/\/github.com\/genuinetools\/amicontained\/releases\" target=\"_blank\" rel=\"noopener\">Releases Page.<\/a> Use the below script from the releases page to install amicontained.<\/p>\n<pre># <span class=\"pl-s1\">Export the sha256sum <span class=\"pl-k\">for<\/span> verification.<\/span>\r\n$ <span class=\"pl-s1\"><span class=\"pl-k\">export<\/span> AMICONTAINED_SHA256=<span class=\"pl-s\"><span class=\"pl-pds\">\"<\/span>d8c49e2cf44ee9668219acd092ed961fc1aa420a6e036e0822d7a31033776c9f<span class=\"pl-pds\">\"<\/span><\/span><\/span>\r\n\r\n# <span class=\"pl-s1\">Download and check the sha256sum.<\/span>\r\n$ <span class=\"pl-s1\">curl -fSL <span class=\"pl-s\"><span class=\"pl-pds\">\"<\/span>https:\/\/github.com\/genuinetools\/amicontained\/releases\/download\/v0.4.9\/amicontained-linux-amd64<span class=\"pl-pds\">\"<\/span><\/span> -o <span class=\"pl-s\"><span class=\"pl-pds\">\"<\/span>\/usr\/local\/bin\/amicontained<span class=\"pl-pds\">\"<\/span><\/span> \\<\/span>\r\n<span class=\"pl-c1\">\t&amp;&amp; echo \"${AMICONTAINED_SHA256}  \/usr\/local\/bin\/amicontained\" | sha256sum -c - \\<\/span>\r\n<span class=\"pl-c1\">\t&amp;&amp; chmod a+x \"\/usr\/local\/bin\/amicontained\"<\/span>\r\n\r\n$ <span class=\"pl-s1\"><span class=\"pl-c1\">echo<\/span> <span class=\"pl-s\"><span class=\"pl-pds\">\"<\/span>amicontained installed!<span class=\"pl-pds\">\"<\/span><\/span><\/span>\r\n\r\n# <span class=\"pl-s1\">Run it<span class=\"pl-k\">!<\/span><\/span>\r\n$ <span class=\"pl-s1\">amicontained -h\r\n\r\n<\/span><\/pre>\n<figure id=\"attachment_4978\" aria-describedby=\"caption-attachment-4978\" style=\"width: 660px\" class=\"wp-caption aligncenter\"><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"4978\" data-permalink=\"https:\/\/www.upnxtblog.com\/index.php\/2020\/04\/22\/do-you-inspect-your-containers\/ami0\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami0.jpg?fit=660%2C129&amp;ssl=1\" data-orig-size=\"660,129\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;S Karthikeyan&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1586251473&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"ami0\" data-image-description=\"&lt;p&gt;amicontained Installation&lt;\/p&gt;\n\" data-image-caption=\"&lt;p&gt;Image &amp;#8211; amicontained Installation&lt;\/p&gt;\n\" data-large-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami0.jpg?fit=660%2C129&amp;ssl=1\" class=\"size-full wp-image-4978 lazyload\" data-src=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami0.jpg?resize=660%2C129&#038;ssl=1\" alt=\"\" width=\"660\" height=\"129\" data-srcset=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami0.jpg?w=660&amp;ssl=1 660w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami0.jpg?resize=300%2C59&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami0.jpg?resize=600%2C117&amp;ssl=1 600w\" data-sizes=\"auto, (max-width: 660px) 100vw, 660px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 660px; --smush-placeholder-aspect-ratio: 660\/129;\" \/><figcaption id=\"caption-attachment-4978\" class=\"wp-caption-text\">Image &#8211; amicontained Installation<\/figcaption><\/figure>\n<p>Verify if we have installed correctly by <code><span class=\"pl-s1\">amicontained -h<\/span><\/code><\/p>\n<figure id=\"attachment_4979\" aria-describedby=\"caption-attachment-4979\" style=\"width: 506px\" class=\"wp-caption aligncenter\"><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"4979\" data-permalink=\"https:\/\/www.upnxtblog.com\/index.php\/2020\/04\/22\/do-you-inspect-your-containers\/ami1\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami1.jpg?fit=506%2C287&amp;ssl=1\" data-orig-size=\"506,287\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;S Karthikeyan&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1586251514&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"ami1\" data-image-description=\"&lt;p&gt;amicontained command line&lt;\/p&gt;\n\" data-image-caption=\"&lt;p&gt;Image &amp;#8211; amicontained command line&lt;\/p&gt;\n\" data-large-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami1.jpg?fit=506%2C287&amp;ssl=1\" class=\"size-full wp-image-4979 lazyload\" data-src=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami1.jpg?resize=506%2C287&#038;ssl=1\" alt=\"\" width=\"506\" height=\"287\" data-srcset=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami1.jpg?w=506&amp;ssl=1 506w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami1.jpg?resize=300%2C170&amp;ssl=1 300w\" data-sizes=\"auto, (max-width: 506px) 100vw, 506px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 506px; --smush-placeholder-aspect-ratio: 506\/287;\" \/><figcaption id=\"caption-attachment-4979\" class=\"wp-caption-text\">Image &#8211; amicontained command line<\/figcaption><\/figure>\n<p>Now that we have successfully installed, we can try out different scenarios.<\/p>\n<h2>Scenario #1: Inspect security configuration<\/h2>\n<p>In this scenario, we are going to inspect our containers for the security configuration.<\/p>\n<figure id=\"attachment_4981\" aria-describedby=\"caption-attachment-4981\" style=\"width: 721px\" class=\"wp-caption aligncenter\"><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"4981\" data-permalink=\"https:\/\/www.upnxtblog.com\/index.php\/2020\/04\/22\/do-you-inspect-your-containers\/ami4\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami4.jpg?fit=721%2C496&amp;ssl=1\" data-orig-size=\"721,496\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;S Karthikeyan&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1586255353&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"ami4\" data-image-description=\"&lt;p&gt;Security Configuration&lt;\/p&gt;\n\" data-image-caption=\"&lt;p&gt;Image &amp;#8211; Security Configuration&lt;\/p&gt;\n\" data-large-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami4.jpg?fit=721%2C496&amp;ssl=1\" class=\"size-full wp-image-4981 lazyload\" data-src=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami4.jpg?resize=721%2C496&#038;ssl=1\" alt=\"\" width=\"721\" height=\"496\" data-srcset=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami4.jpg?w=721&amp;ssl=1 721w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami4.jpg?resize=300%2C206&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami4.jpg?resize=600%2C413&amp;ssl=1 600w\" data-sizes=\"auto, (max-width: 721px) 100vw, 721px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 721px; --smush-placeholder-aspect-ratio: 721\/496;\" \/><figcaption id=\"caption-attachment-4981\" class=\"wp-caption-text\">Image &#8211; Security Configuration<\/figcaption><\/figure>\n<figure id=\"attachment_4980\" aria-describedby=\"caption-attachment-4980\" style=\"width: 723px\" class=\"wp-caption aligncenter\"><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"4980\" data-permalink=\"https:\/\/www.upnxtblog.com\/index.php\/2020\/04\/22\/do-you-inspect-your-containers\/ami5\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami5.jpg?fit=723%2C288&amp;ssl=1\" data-orig-size=\"723,288\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;S Karthikeyan&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1586255372&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"ami5\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami5.jpg?fit=723%2C288&amp;ssl=1\" class=\"wp-image-4980 size-full lazyload\" data-src=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami5.jpg?resize=723%2C288&#038;ssl=1\" alt=\"Security Configuration\" width=\"723\" height=\"288\" data-srcset=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami5.jpg?w=723&amp;ssl=1 723w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami5.jpg?resize=300%2C120&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami5.jpg?resize=600%2C239&amp;ssl=1 600w\" data-sizes=\"auto, (max-width: 723px) 100vw, 723px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 723px; --smush-placeholder-aspect-ratio: 723\/288;\" \/><figcaption id=\"caption-attachment-4980\" class=\"wp-caption-text\">Image &#8211; Security Configuration<\/figcaption><\/figure>\n<p>We could see that what are the allowed\/blocked syscalls, container runtime, AppArmor profile, capabilities, etc.,<\/p>\n<h2>Scenario #2: Inspect PID Namespace<\/h2>\n<p>By default, all containers have the PID namespace enabled. PID namespace provides separation of processes. The PID Namespace removes the view of the system processes and allows process ids to be reused.<\/p>\n<p>In this scenario, we are going to inspect the container with PID namespace as host basically allowing processes within the container to see all of the processes on the system and check the output.<\/p>\n<figure id=\"attachment_4983\" aria-describedby=\"caption-attachment-4983\" style=\"width: 720px\" class=\"wp-caption aligncenter\"><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"4983\" data-permalink=\"https:\/\/www.upnxtblog.com\/index.php\/2020\/04\/22\/do-you-inspect-your-containers\/ami2\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami2.jpg?fit=720%2C214&amp;ssl=1\" data-orig-size=\"720,214\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;S Karthikeyan&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1586255112&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"ami2\" data-image-description=\"&lt;p&gt;Namespace configuration&lt;\/p&gt;\n\" data-image-caption=\"&lt;p&gt;Image &amp;#8211; Namespace configuration&lt;\/p&gt;\n\" data-large-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami2.jpg?fit=720%2C214&amp;ssl=1\" class=\"size-full wp-image-4983 lazyload\" data-src=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami2.jpg?resize=720%2C214&#038;ssl=1\" alt=\"\" width=\"720\" height=\"214\" data-srcset=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami2.jpg?w=720&amp;ssl=1 720w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami2.jpg?resize=300%2C89&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami2.jpg?resize=600%2C178&amp;ssl=1 600w\" data-sizes=\"auto, (max-width: 720px) 100vw, 720px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 720px; --smush-placeholder-aspect-ratio: 720\/214;\" \/><figcaption id=\"caption-attachment-4983\" class=\"wp-caption-text\">Image &#8211; Namespace configuration<\/figcaption><\/figure>\n<h2>Scenario #3: Inspect Container runtime, environment<\/h2>\n<p>In this scenario, we are going to run the container with PID namespace as host basically allowing processes within the container to see all of the processes on the system and check the output.<\/p>\n<figure id=\"attachment_4984\" aria-describedby=\"caption-attachment-4984\" style=\"width: 727px\" class=\"wp-caption aligncenter\"><img data-recalc-dims=\"1\" decoding=\"async\" data-attachment-id=\"4984\" data-permalink=\"https:\/\/www.upnxtblog.com\/index.php\/2020\/04\/22\/do-you-inspect-your-containers\/ami3\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami3.jpg?fit=727%2C226&amp;ssl=1\" data-orig-size=\"727,226\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;S Karthikeyan&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1586255163&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"ami3\" data-image-description=\"&lt;p&gt;Check container runtime&lt;\/p&gt;\n\" data-image-caption=\"&lt;p&gt;Image &amp;#8211; Check container runtime&lt;\/p&gt;\n\" data-large-file=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami3.jpg?fit=727%2C226&amp;ssl=1\" class=\"size-full wp-image-4984 lazyload\" data-src=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami3.jpg?resize=727%2C226&#038;ssl=1\" alt=\"\" width=\"727\" height=\"226\" data-srcset=\"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami3.jpg?w=727&amp;ssl=1 727w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami3.jpg?resize=300%2C93&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/04\/ami3.jpg?resize=600%2C187&amp;ssl=1 600w\" data-sizes=\"auto, (max-width: 727px) 100vw, 727px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 727px; --smush-placeholder-aspect-ratio: 727\/226;\" \/><figcaption id=\"caption-attachment-4984\" class=\"wp-caption-text\">Image &#8211; Check container runtime,environment<\/figcaption><\/figure>\n<p><em>Congrats! we have learned how to inspect containers using amicontained tool.<\/em><\/p>\n<h2>Docker container security best practices<\/h2>\n<p>Following best practices can help you create a Docker security infrastructure:<\/p>\n<ol>\n<li>Container images act as a foundation for multiple systems, and vulnerable images can cause damage across your enterprise. You need to ensure images are protected by s<strong>canning for open source and third-party vendor containers and setting up a trusted registry of base images.<\/strong><\/li>\n<li>Sensitive information such as passwords and addresses <strong>needs to be maintained using Docker secrets.<\/strong><\/li>\n<li>Monitor your container activity and<strong> limit the use of resources.<\/strong> Design errors, software bugs, or malware attacks can often lead to DoS attacks. You can handle the large attack surface by limiting the number of system resources allotted for each container.<\/li>\n<li>SECCOMP provides a default profile that blocks 44 out of the 300+ system calls allowed on Docker containers and lets you manage a whitelist to block additional types of calls. You have the option to use a <strong>strict SECCOMP profile<\/strong> to prevent some types of attacks and preventing others from spreading to the rest of the infrastructure.<\/li>\n<li>Monitoring systems like <a href=\"https:\/\/www.upnxtblog.com\/index.php\/2019\/03\/05\/monitoring-docker-containers-using-prometheus-cadvisor-grafana\/\">Prometheus<\/a> can<strong> help you identify attacks, send alerts,<\/strong> and even automatically implement fixes. <strong>Periodically review log data<\/strong> generated by containers and use it to generate preventive security insights.<\/li>\n<li>Know the composition of your containers during runtime as well as build time.<\/li>\n<\/ol>\n<p>If you&#8217;re looking for Docker <a href=\"https:\/\/www.upnxtblog.com\/index.php\/2018\/03\/26\/8-best-docker-security-tools\/\">Security tools, check out here.<\/a><\/p>\n<p><em><strong>Like this post? Don\u2019t forget to share it!<\/strong><\/em><\/p>\n<h2>Additional Resources :<\/h2>\n<ul>\n<li><a href=\"https:\/\/www.upnxtblog.com\/index.php\/2019\/01\/04\/implementing-secure-containers-using-gvisordocker-tutorial\/\">Implementing secure containers using gVisor+Docker tutorial<\/a><\/li>\n<li><a href=\"https:\/\/www.upnxtblog.com\/index.php\/2019\/10\/03\/secure-coding-practices-specialization-by-uc-davis\/\">Secure Coding Practices Specialization by UC Davis<\/a><\/li>\n<li><a href=\"https:\/\/www.upnxtblog.com\/index.php\/2019\/12\/09\/implementing-policies-in-kubernetes\/\">Implementing Policies in Kubernetes<\/a><\/li>\n<li><a href=\"https:\/\/www.upnxtblog.com\/index.php\/2019\/11\/25\/using-docker-application-packages-to-deliver-apps-across-teams\/\">Using Docker Application Packages to Deliver Apps across Teams<\/a><\/li>\n<li><a href=\"https:\/\/www.upnxtblog.com\/index.php\/2019\/09\/09\/get-job-ready-with-professional-certificates-from-coursera\/\">Get Job Ready with Professional Certificates from Coursera<\/a><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>With the increasing adoption of containers and microservices in the enterprises, there are also risks that come along with containers. For example, If any one of the containers breaks out, it can allow unauthorized access across containers, hosts, or data centers, etc., thus affecting all the containers hosted on the Host OS. To mitigate these [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":1061,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"nf_dc_page":"","_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[310,311],"tags":[403,53,149],"class_list":["post-4971","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-docker","category-kubernetes","tag-amicontained","tag-docker","tag-kubernetes"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/11\/docker_facebook_share.png?fit=336%2C287&ssl=1","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p9fbQS-1ib","jetpack-related-posts":[{"id":415,"url":"https:\/\/www.upnxtblog.com\/index.php\/2017\/09\/07\/10-things-know-containerization-technology\/","url_meta":{"origin":4971,"position":0},"title":"10 things you should know about containerization technology","author":"Karthik","date":"September 7, 2017","format":false,"excerpt":"Linux containers have been around since the early 2000s and architected into Linux in 2007. Due to the small footprint and portability of containers, the same hardware can support an exponentially larger number of containers than VMs, dramatically reducing infrastructure costs and enabling more apps to deploy faster. But due\u2026","rel":"","context":"In &quot;Cloud Computing&quot;","block_context":{"text":"Cloud Computing","link":"https:\/\/www.upnxtblog.com\/index.php\/category\/cloud\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/09\/container2.png?fit=638%2C343&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/09\/container2.png?fit=638%2C343&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/09\/container2.png?fit=638%2C343&ssl=1&resize=525%2C300 1.5x"},"classes":[]},{"id":4580,"url":"https:\/\/www.upnxtblog.com\/index.php\/2020\/02\/10\/key-takeaways-from-containers-adoption-use-cases-2019-survey-results\/","url_meta":{"origin":4971,"position":1},"title":"Key takeaways from Containers Adoption &#038; Use Cases 2019 Survey Results","author":"Karthik","date":"February 10, 2020","format":false,"excerpt":"Around Nov 2019, I have reached out to you all on Containers Adoption & Use Cases survey to evaluate how enterprises are currently using containers and what challenges, benefits they are experiencing. There were about 700+ responses, Thank you! everyone, who has participated, and here are the key takeaways from\u2026","rel":"","context":"In &quot;Docker Guides&quot;","block_context":{"text":"Docker Guides","link":"https:\/\/www.upnxtblog.com\/index.php\/category\/docker\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/01\/container9.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/01\/container9.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/01\/container9.png?resize=525%2C300&ssl=1 1.5x"},"classes":[]},{"id":7472,"url":"https:\/\/www.upnxtblog.com\/index.php\/2023\/10\/16\/scalable-data-management-for-docker-containers-harnessing-nas-appliances\/","url_meta":{"origin":4971,"position":2},"title":"Scalable Data Management for Docker Containers: Harnessing NAS Appliances","author":"Karthik","date":"October 16, 2023","format":false,"excerpt":"The rise of containerized applications has revolutionized the world of software development. Docker containers have simplified the deployment process, enabling developers to deliver software quickly and reliably. However, managing data within these containers can be challenging, especially when it comes to scaling. To tackle this challenge, network attached storage (NAS)\u2026","rel":"","context":"In &quot;Docker Guides&quot;","block_context":{"text":"Docker Guides","link":"https:\/\/www.upnxtblog.com\/index.php\/category\/docker\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2023\/10\/doc4.png?fit=702%2C465&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2023\/10\/doc4.png?fit=702%2C465&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2023\/10\/doc4.png?fit=702%2C465&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2023\/10\/doc4.png?fit=702%2C465&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":3179,"url":"https:\/\/www.upnxtblog.com\/index.php\/2019\/01\/04\/implementing-secure-containers-using-gvisordocker-tutorial\/","url_meta":{"origin":4971,"position":3},"title":"Implementing secure containers using gVisor+Docker tutorial","author":"Karthik","date":"January 4, 2019","format":false,"excerpt":"Linux containers have been around since the early 2000s and architected into Linux in 2007. Due to the small footprint and portability of containers, the same hardware can support an exponentially larger number of containers than VMs, dramatically reducing infrastructure costs and enabling more apps to deploy faster. But due\u2026","rel":"","context":"In &quot;Docker Guides&quot;","block_context":{"text":"Docker Guides","link":"https:\/\/www.upnxtblog.com\/index.php\/category\/docker\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/10\/google_chrome-logo.png?fit=800%2C473&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/10\/google_chrome-logo.png?fit=800%2C473&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/10\/google_chrome-logo.png?fit=800%2C473&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2017\/10\/google_chrome-logo.png?fit=800%2C473&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":4831,"url":"https:\/\/www.upnxtblog.com\/index.php\/2020\/01\/29\/take-look-at-podman-red-hats-daemon-less-docker-alternative\/","url_meta":{"origin":4971,"position":4},"title":"Take look at Podman, Red Hat&#8217;s daemon-less Docker Alternative","author":"Karthik","date":"January 29, 2020","format":false,"excerpt":"Podman is a new, open-source, container engine that works seamlessly with containers as well as pods. This project is different because it doesn\u2019t actually depend on a daemon(like Docker), but instead launches containers and pods as child processes. Podman is the CLI tool for interacting with libpod, a library that\u2026","rel":"","context":"In &quot;Docker Guides&quot;","block_context":{"text":"Docker Guides","link":"https:\/\/www.upnxtblog.com\/index.php\/category\/docker\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/01\/podman.jpg?fit=880%2C218&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/01\/podman.jpg?fit=880%2C218&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/01\/podman.jpg?fit=880%2C218&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2020\/01\/podman.jpg?fit=880%2C218&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":1748,"url":"https:\/\/www.upnxtblog.com\/index.php\/2018\/01\/17\/top-6-gui-tools-for-managing-docker-environments\/","url_meta":{"origin":4971,"position":5},"title":"TOP 6 GUI tools for managing Docker environments","author":"Karthik","date":"January 17, 2018","format":false,"excerpt":"Before we start, a little bit of intro on Containers, its an abstraction at the app layer that packages code and dependencies together. Multiple containers can run on the same machine and share the OS kernel with other containers, each running as isolated processes in userspace. Containers take up less\u2026","rel":"","context":"In &quot;Docker Guides&quot;","block_context":{"text":"Docker Guides","link":"https:\/\/www.upnxtblog.com\/index.php\/category\/docker\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2018\/01\/dashboard.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2018\/01\/dashboard.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2018\/01\/dashboard.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2018\/01\/dashboard.png?resize=700%2C400&ssl=1 2x, https:\/\/i0.wp.com\/www.upnxtblog.com\/wp-content\/uploads\/2018\/01\/dashboard.png?resize=1050%2C600&ssl=1 3x"},"classes":[]}],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/posts\/4971","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/comments?post=4971"}],"version-history":[{"count":2,"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/posts\/4971\/revisions"}],"predecessor-version":[{"id":5637,"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/posts\/4971\/revisions\/5637"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/media\/1061"}],"wp:attachment":[{"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/media?parent=4971"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/categories?post=4971"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.upnxtblog.com\/index.php\/wp-json\/wp\/v2\/tags?post=4971"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}