<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Nginx-UI (&gt;= 2.0.0, &lt;= 2.3.5) — CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/products/nginx-ui--2.0.0--2.3.5/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata — refreshed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Wed, 03 Jan 2024 17:22:00 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/products/nginx-ui--2.0.0--2.3.5/feed.xml" rel="self" type="application/rss+xml"/><item><title>Nginx-UI Unauthenticated Initial Admin Claim Vulnerability</title><link>https://feed.craftedsignal.io/briefs/2024-01-nginx-ui-initial-admin-takeover/</link><pubDate>Wed, 03 Jan 2024 17:22:00 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2024-01-nginx-ui-initial-admin-takeover/</guid><description>An unauthenticated network attacker can claim the initial administrator account on a fresh Nginx-UI instance during the first-run setup window by exploiting the publicly accessible /api/install endpoint.</description><content:encoded><![CDATA[<p>The <code>nginx-ui</code> application versions 2.0.0 through 2.3.5 are vulnerable to an unauthenticated initial administrator claim. An attacker can exploit this by sending a POST request to the <code>/api/install</code> endpoint during the first-run setup window. This allows the attacker to set the admin email, username, and password, effectively taking control of the application before the legitimate administrator. The vulnerability exists because the <code>/api/install</code> endpoint lacks proper authentication and the request-encryption flow only protects confidentiality, not authenticity. This can lead to complete compromise of the Nginx-UI instance and the systems it manages.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>A fresh <code>nginx-ui</code> instance is deployed and exposed to the network.</li>
<li>An unauthenticated attacker sends a GET request to <code>/api/install</code> to verify the instance is unlocked (<code>&quot;lock&quot;: false, &quot;timeout&quot;: false</code>).</li>
<li>The attacker sends a POST request to <code>/api/crypto/public_key</code> to obtain the server&rsquo;s RSA public key.</li>
<li>The attacker encrypts a JSON payload containing the attacker&rsquo;s desired admin email, username, and password using the obtained public key. The payload is formatted as <code>{&quot;email&quot;:&quot;attacker@example.com&quot;,&quot;username&quot;:&quot;attacker&quot;,&quot;password&quot;:&quot;Password12345&quot;}</code>.</li>
<li>The attacker base64-encodes the resulting ciphertext.</li>
<li>The attacker sends a POST request to <code>/api/install</code> with the base64-encoded ciphertext in the <code>encrypted_params</code> field (e.g., <code>{&quot;encrypted_params&quot;:&quot;base64_encoded_ciphertext&quot;}</code>).</li>
<li>The server overwrites the initial admin user (ID 1) in the database with the attacker-provided credentials.</li>
<li>The attacker logs in to the <code>nginx-ui</code> interface with the attacker-controlled username and password, gaining complete control of the application.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful exploitation allows an attacker to gain complete control over the <code>nginx-ui</code> application. Since <code>nginx-ui</code> manages Nginx configurations, certificates, and other host-level settings, this can lead to unauthorized configuration changes, certificate management abuse, backup manipulation, service disruption, and broader operational takeover of the managed environment. This vulnerability affects fresh, uninitialized instances that are reachable over the network during the installation window.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Deploy the Sigma rule &ldquo;Detect Nginx-UI Unauthenticated Initial Admin Claim Attempt&rdquo; to your SIEM to identify exploitation attempts based on requests to the <code>/api/install</code> endpoint.</li>
<li>Apply network access controls to restrict access to the <code>nginx-ui</code> instance during the installation window.</li>
<li>Monitor web server logs for POST requests to <code>/api/install</code> and <code>/api/crypto/public_key</code> from unusual source IP addresses.</li>
</ul>
]]></content:encoded><category domain="severity">medium</category><category domain="type">advisory</category><category>nginx-ui</category><category>initial-access</category><category>authentication-bypass</category></item></channel></rss>