{"id":2575,"date":"2022-03-15T13:00:00","date_gmt":"2022-03-15T19:00:00","guid":{"rendered":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/?p=2575"},"modified":"2022-03-15T12:30:40","modified_gmt":"2022-03-15T18:30:40","slug":"linux-dirty-pipe-vulnerability-raises-concern-among-security-experts","status":"publish","type":"post","link":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/2022\/03\/15\/linux-dirty-pipe-vulnerability-raises-concern-among-security-experts\/","title":{"rendered":"Linux &#8220;Dirty Pipe&#8221; Vulnerability Raises Concern Among Security Experts"},"content":{"rendered":"\n<p>While file permissions are extremely crucial to the security of Linux systems, a vulnerability has recently been discovered which allows users to bypass these permissions and escalate privileges. A vulnerability called <a rel=\"noreferrer noopener\" href=\"https:\/\/cve.mitre.org\/cgi-bin\/cvename.cgi?name=CVE-2022-0847\" target=\"_blank\">CVE-2022-0847<\/a> (nicknamed \u201cDirty Pipe\u201d) allows people to write to read-only files and fill them with arbitrary information. This can allow someone to completely takeover a system with access to sensitive linux root files. This vulnerability affects Linux versions 5.8 and above.<\/p>\n\n\n\n<p>Max Kellerman, a software developer at IONOS discovered this vulnerability after one of his customers raised concerns about file corruption. Specific files that were downloaded by the customer could not be decompressed which led to this important finding. Apparently, the pipe buffer structure was not properly initialized which led to this kind of file corruption.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">What is a Pipe?<\/h3>\n\n\n\n<p>In Linux, a pipe is a mechanism that allows for processes on a computer to communicate with each other. It allows users to conveniently send the output of a process into the input of another process. An example of this in the terminal is as follows:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"499\" data-src=\"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-content\/uploads\/sites\/115\/2022\/03\/Screen-Shot-2022-03-14-at-12.32.54-PM-1024x499.png\" alt=\"\" class=\"wp-image-2590 lazyload\" data-srcset=\"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-content\/uploads\/sites\/115\/2022\/03\/Screen-Shot-2022-03-14-at-12.32.54-PM-1024x499.png 1024w, https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-content\/uploads\/sites\/115\/2022\/03\/Screen-Shot-2022-03-14-at-12.32.54-PM-300x146.png 300w, https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-content\/uploads\/sites\/115\/2022\/03\/Screen-Shot-2022-03-14-at-12.32.54-PM-768x375.png 768w, https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-content\/uploads\/sites\/115\/2022\/03\/Screen-Shot-2022-03-14-at-12.32.54-PM.png 1464w\" data-sizes=\"(max-width: 1024px) 100vw, 1024px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 1024px; --smush-placeholder-aspect-ratio: 1024\/499;\" \/><figcaption>The above commands demonstrate how pipes are used in the terminal. The | symbol is used to create a pipe between two processes.<\/figcaption><\/figure>\n\n\n\n<p>In the above image, the command \u201ccat hello.txt\u201d returns all the contents of the file \u201chello.txt\u201d. The command \u201ccat hello.txt | head -3\u201d feeds the output of the \u201ccat hello.txt\u201d process into the \u201chead -3\u201d process which returns then the first 3 lines of the input it is given.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" style=\"text-transform:capitalize\">How Does the Exploit Work?<\/h3>\n\n\n\n<p>There following are the steps used to exploit this vulnerability:<\/p>\n\n\n\n<ol class=\"wp-block-list\" type=\"1\"><li>Open a pipe<\/li><li>Fill pipe with arbitrary data<\/li><li>Clear the pipe (this allows for data in the pipe to be merged with other data)<\/li><li>Feed in data from the target file into the pipe<\/li><li>Write some data into the pipe<\/li><\/ol>\n\n\n\n<p>As a result of following these steps, the system incorrectly overwrites the cached copy of the target file with data in the pipe. Max Kellermann has written about this in more detail <a href=\"https:\/\/dirtypipe.cm4all.com\/\">here<\/a>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">How can this vulnerability be exploited?<\/h3>\n\n\n\n<p>The following are examples of exploits:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Overwriting crucial system files such as \/etc\/passwd to remove the password of the root user<\/li><li>Adding ssh keys allowing for remote access to a system<\/li><li>Overwriting and executing binaries to tamper with the system<\/li><\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">Effect on Smartphones<\/h3>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" data-src=\"https:\/\/www.androidauthority.com\/wp-content\/uploads\/2022\/02\/Samsung-Galaxy-S22-Plus-vs-Google-Pixel-6-rear-on-table.jpg\" alt=\"Samsung Galaxy S22 vs Google Pixel 6: Which one should you buy?\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" class=\"lazyload\" \/><figcaption>Google Pixel 6 and Samsung Galaxy S22<\/figcaption><\/figure>\n\n\n\n<p>Since the android operating system is built on top of a Linux kernel, there are many questions being raised regarding the security of Android smartphones. &nbsp;Fortunately, most Android devices use older kernel versions not affected by Dirty Pipe. This vulnerability has been patched for versions 5.16.11, 5.15.25, and 5.10.102.&nbsp; Google has merged the fixes into the Android kernel however, this does not secure all its devices. The devices likely to be affected are the ones that use Android 12 up. This means that new phones such as the Google Pixel 6 series and Samsung Galaxy S22 are at high risk. For users to stay well informed, it is important to find out about the Linux kernel that their device is using. This can be done by going to <strong>Settings<\/strong>&nbsp;&gt;&nbsp;<strong>About phone<\/strong>&nbsp;&gt;&nbsp;<strong>Android\/Software version<\/strong>&nbsp;&gt;&nbsp;<strong>Kernel version<\/strong>. IPhone users will be unaffected by this vulnerability as the OS is not built on a Linux kernel.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">References<\/h3>\n\n\n\n<ol class=\"wp-block-list\"><li><a href=\"https:\/\/blog.malwarebytes.com\/exploits-and-vulnerabilities\/2022\/03\/linux-dirty-pipe-vulnerability-gives-unprivileged-users-root-access\/\">https:\/\/blog.malwarebytes.com\/exploits-and-vulnerabilities\/2022\/03\/linux-dirty-pipe-vulnerability-gives-unprivileged-users-root-access\/<\/a><\/li><li><a href=\"https:\/\/redhuntlabs.com\/blog\/the-dirty-pipe-vulnerability.html\">https:\/\/redhuntlabs.com\/blog\/the-dirty-pipe-vulnerability.html<\/a><\/li><li><a href=\"https:\/\/www.google.com\/url?sa=i&amp;url=https%3A%2F%2Fwww.androidauthority.com%2Fsamsung-galaxy-s22-vs-google-pixel-6-3103491%2F&amp;psig=AOvVaw0hhkO4k7Cy75Gih82XVKFl&amp;ust=1647452312997000&amp;source=images&amp;cd=vfe&amp;ved=0CAgQjRxqFwoTCJCigqLUyPYCFQAAAAAdAAAAABAD\">https:\/\/www.google.com\/url?sa=i&amp;url=https%3A%2F%2Fwww.androidauthority.com%2Fsamsung-galaxy-s22-vs-google-pixel-6-3103491%2F&amp;psig=AOvVaw0hhkO4k7Cy75Gih82XVKFl&amp;ust=1647452312997000&amp;source=images&amp;cd=vfe&amp;ved=0CAgQjRxqFwoTCJCigqLUyPYCFQAAAAAdAAAAABAD<\/a><\/li><li><a href=\"https:\/\/thehackernews.com\/2022\/03\/researchers-warn-of-linux-kernel-dirty.html\">https:\/\/thehackernews.com\/2022\/03\/researchers-warn-of-linux-kernel-dirty.html<\/a><\/li><li><a href=\"https:\/\/9to5google.com\/2022\/03\/14\/dirty-pipe-major-exploit-android-12-pixel-6-galaxy-s22\/\">https:\/\/9to5google.com\/2022\/03\/14\/dirty-pipe-major-exploit-android-12-pixel-6-galaxy-s22\/<\/a><\/li><\/ol>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>While file permissions are extremely crucial to the security of Linux systems, a vulnerability has recently been discovered which allows users to bypass these permissions and escalate privileges. A vulnerability called CVE-2022-0847 (nicknamed \u201cDirty Pipe\u201d) allows people to write to read-only files and fill them with arbitrary information. This can allow someone to completely takeover &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/2022\/03\/15\/linux-dirty-pipe-vulnerability-raises-concern-among-security-experts\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Linux &#8220;Dirty Pipe&#8221; Vulnerability Raises Concern Among Security Experts&#8221;<\/span><\/a><\/p>\n","protected":false},"author":378,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0,"footnotes":""},"categories":[15],"tags":[],"class_list":["post-2575","post","type-post","status-publish","format-standard","hentry","category-cpsc-329-602-w22","entry"],"featured_image_src":null,"featured_image_src_square":null,"author_info":{"display_name":"Firoz Lakhani","author_link":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/author\/firoz-lakhani\/"},"_links":{"self":[{"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/posts\/2575","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/users\/378"}],"replies":[{"embeddable":true,"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/comments?post=2575"}],"version-history":[{"count":2,"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/posts\/2575\/revisions"}],"predecessor-version":[{"id":2593,"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/posts\/2575\/revisions\/2593"}],"wp:attachment":[{"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/media?parent=2575"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/categories?post=2575"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpsites.ucalgary.ca\/isec-601-f21\/wp-json\/wp\/v2\/tags?post=2575"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}