{"id":27232,"date":"2022-11-01T18:27:04","date_gmt":"2022-11-01T17:27:04","guid":{"rendered":"http:\/\/159.69.82.204\/win\/?p=27232"},"modified":"2022-11-01T18:27:04","modified_gmt":"2022-11-01T17:27:04","slug":"nginx-for-windows-von-openssl-privilegien-schwachstelle-betroffen","status":"publish","type":"post","link":"https:\/\/borncity.com\/win\/2022\/11\/01\/nginx-for-windows-von-openssl-privilegien-schwachstelle-betroffen\/","title":{"rendered":"nginx for Windows affected by OpenSSL privilege vulnerability"},"content":{"rendered":"<p><img decoding=\"async\" title=\"Sicherheit (Pexels, allgemeine Nutzung)\" style=\"float: left; margin: 0px 10px 0px 0px; display: inline\" alt=\"Sicherheit (Pexels, allgemeine Nutzung)\" src=\"https:\/\/www.borncity.com\/blog\/wp-content\/uploads\/2021\/04\/Sicherheit_klein.jpg\" width=\"200\" align=\"left\">[<a href=\"https:\/\/www.borncity.com\/blog\/2022\/11\/01\/nginx-for-windows-von-openssl-privilegien-schwachstelle-betroffen\/\" target=\"_blank\" rel=\"noopener\">German<\/a>]Those who use nginx on Windows as a web server, reverse proxy and email proxy may have a problem. Sombody just found out that nginx for Windows in various versions like 1.22.1 has a vulnerability that allows privilege elevation for normal users. The reason is that the used OpenSSL library is loaded from a path that can be manipulated. <\/p>\n<p><!--more--><\/p>\n<h2>nginx for Windows with vulnerability<\/h2>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"https:\/\/vg07.met.vgwort.de\/na\/0ca14744d4ea4750a731b7844d0337b3\" width=\"1\" height=\"1\">I just became aware on Twitter from a <a href=\"https:\/\/twitter.com\/wdormann\/status\/1587442898819338240\" target=\"_blank\" rel=\"noopener\">tweet<\/a> by Will Dormann that nginx for Windows has a vulnerability related to the OpenSSL library that allows privilege escalation. <\/p>\n<p><a href=\"https:\/\/twitter.com\/wdormann\/status\/1587442898819338240\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" title=\"vulnerability in nginx for Windows\" alt=\"vulnerability in nginx for Windows\" src=\"https:\/\/i.imgur.com\/HExvYwm.png\"><\/a><\/p>\n<p>On the nginx site there is <a href=\"https:\/\/trac.nginx.org\/nginx\/ticket\/2404\" target=\"_blank\" rel=\"noopener\">this ticket<\/a> where someone states that the official Windows builds of nginx contain a vulnerability. Once nginx is started, it tries to load the OpenSSL configuration file from:<\/p>\n<pre><code>C:\\MinGW\\msys\\1.0\\home\\Administrator\\nginx\\objs.msvc8\\lib\\openssl-1.1.1q\\openssl\\ssl\\openssl.cnf<\/code><\/pre>\n<p>Unfortunately, any user with standard privileges can create this path with the folders and write to the file if it exists. An attacker could manipulate <em>openssl.cnf<\/em> to load an arbitrary OpenSSL engine library on some path. <\/p>\n<p>This can potentially be exploited for privilege escalation by injecting an arbitrary OpenSSL engine library. In many cases, nginx is run either by an administrator or in the context of NT AUTHORITY\\SYSTEM, resulting in privilege escalation if malicious code is reloaded from the OpenSSL engine library.<\/p>\n<p>The flaw was tested with nginx-1.22.1 (stable) and 1.23.2 (mainline) on Windows 10 21H2. The tester who created the ticket suspects that the bug was first introduced in the legacy build nginx-1.20.2.zip.<\/p>\n<h2>What is nginx?<\/h2>\n<p><a href=\"https:\/\/en.wikipedia.org\/wiki\/Nginx\" target=\"_blank\" rel=\"noopener\">nginx<\/a> is a web server that can also be used as a reverse proxy, load balancer, mail proxy and HTTP cache. The software was developed by Igor Sysoev and released in 2004. Nginx is free and open source software released under the terms of the BSD license with two clauses. A large portion of web servers use Nginx, often as a load balancer. <\/p>\n<p>I could imagine that nginx for Windows is used as a reverse proxy for Microsoft Exchange to isolate this software from the Internet. At least that's what I've heard on Facebook and <a href=\"https:\/\/www.borncity.com\/blog\/2022\/10\/04\/exchange-server-microsofts-0-day-schutz-aushebelbar-neue-einschtzungen-3-oktober-2022\/#comment-133422\" target=\"_blank\" rel=\"noopener\">within my German blog<\/a>.&nbsp;&nbsp;&nbsp;&nbsp; <\/p>\n<blockquote>\n<p>At the moment the whole software industry is waiting for details about a vulnerability in OpenSSL that is classified as critical. OpenSSL is a widely used code library that enables secure communication over the Internet. OpenSSL includes implementations of network protocols and various ciphers. As of Oct. 31, 2022, I addressed the topci within the blog post <a title=\"https:\/\/www.borncity.com\/blog\/2022\/10\/31\/hinweis-patch-fr-openssl-schwachstelle-zum-1-nov-2022\/\" href=\"https:\/\/borncity.com\/win\/2022\/10\/31\/hinweis-patch-fr-openssl-schwachstelle-zum-1-nov-2022\/\">OpenSSL 3.0.7 with patch for vulnerability on Nov. 1, 2022 announced<\/a>. But the bug mentioned above has nothing to do with the vulnerability in OpenSSL. <\/p>\n<\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>[German]Those who use nginx on Windows as a web server, reverse proxy and email proxy may have a problem. Sombody just found out that nginx for Windows in various versions like 1.22.1 has a vulnerability that allows privilege elevation for &hellip; <a href=\"https:\/\/borncity.com\/win\/2022\/11\/01\/nginx-for-windows-von-openssl-privilegien-schwachstelle-betroffen\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[580,1547,2],"tags":[2750,69,194],"class_list":["post-27232","post","type-post","status-publish","format-standard","hentry","category-security","category-software","category-windows","tag-nginx","tag-security","tag-windows"],"_links":{"self":[{"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/posts\/27232","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/comments?post=27232"}],"version-history":[{"count":0,"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/posts\/27232\/revisions"}],"wp:attachment":[{"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/media?parent=27232"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/categories?post=27232"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/borncity.com\/win\/wp-json\/wp\/v2\/tags?post=27232"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}