Skip to main content
Vulnerability Database/CVE-2026-105645

CVE-2026-105645: Ghost CMS Denial of Service Vulnerability

CVE-2026-105645 is a denial of service vulnerability in Ghost CMS that allows attackers with admin access to cause excessive CPU usage. This post explains its impact, affected versions, and mitigation steps.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-105645 Overview

CVE-2026-105645 is a denial-of-service vulnerability in Ghost, the Node.js content management system maintained by TryGhost. A crafted request to the external media inliner can trigger excessive CPU consumption, rendering the Ghost server unresponsive. The flaw affects versions 5.37.0 through 6.66.x and is fixed in 6.67.0. Exploitation requires Administrator-level access to the Ghost instance, which limits the attacker population but still enables a privileged user or a compromised admin account to disrupt the publishing platform. The weakness is classified as [CWE-1333] Inefficient Regular Expression Complexity, a pattern commonly associated with ReDoS-style resource exhaustion.

Critical Impact

An authenticated administrator can submit a crafted input to the external media inliner that drives CPU utilization high enough to render the Ghost server unresponsive to legitimate requests.

Affected Products

  • Ghost 5.37.0 through 6.66.x (Node.js content management system)
  • Self-hosted Ghost deployments using the external media inliner feature
  • Ghost import handlers that build regular expressions from user-controlled directory names

Discovery Timeline

  • 2026-10-05 - CVE-2026-105645 published to the National Vulnerability Database
  • 2026-10-06 - Last updated in NVD database

Technical Details for CVE-2026-105645

Vulnerability Analysis

The vulnerability lives in Ghost's external media inliner and import handlers, which construct regular expressions from input strings without escaping regex metacharacters. When an administrator triggers an operation that uses these handlers with a crafted directory or URL value, the resulting pattern can produce catastrophic backtracking against processed content. The Node.js regex engine blocks the event loop while evaluating the pattern, which starves other requests and makes the server appear hung. Because Ghost runs as a single-process Node.js application by default, event-loop stalls translate directly into platform-wide unresponsiveness.

Root Cause

The root cause is unescaped user-controlled input flowing into new RegExp(...) constructors inside ghost/core/core/server/data/importer/handlers/image.js and importer-content-file-handler.js. The baseDir value and staticFileURLPrefix segments were concatenated directly into regex source strings, allowing metacharacters such as ., +, *, (, and | to alter pattern semantics. This classifies as [CWE-1333] Inefficient Regular Expression Complexity.

Attack Vector

An authenticated administrator submits a request to the external media inliner (or triggers an import) with a payload that causes the handler to build a pathological regular expression. Evaluation of that regex against subsequent inputs consumes CPU for an extended duration, preventing Ghost from servicing additional requests until the operation completes or the process is restarted.

javascript
// Patch: ghost/core/core/server/data/importer/handlers/image.js
 loadFile: function (files, baseDir) {
   const store = adapterManager.getAdapter('storage:images');
-  const baseDirRegex = baseDir ? new RegExp('^' + baseDir + '/') : new RegExp('');
+  const baseDirRegex = baseDir ? new RegExp('^' + _.escapeRegExp(baseDir) + '/') : new RegExp('');

   const imageFolderRegexes = _.map(store.staticFileURLPrefix.split('/'), function (dir) {
-    return new RegExp('^' + dir + '/');
+    return new RegExp('^' + _.escapeRegExp(dir) + '/');
   });
// Source: https://github.com/TryGhost/Ghost/commit/88ae6d6d56f8a239cb38a8c89de02f034f50e2ce

The fix wraps every user-influenced value with Lodash _.escapeRegExp so that metacharacters are treated as literals, eliminating the pathological pattern construction. The same change is applied in importer-content-file-handler.js for the content-file loader.

Detection Methods for CVE-2026-105645

Indicators of Compromise

  • Sustained single-core CPU saturation on the Ghost Node.js process without a corresponding increase in request throughput.
  • Ghost admin audit logs showing external media inliner invocations or import operations immediately before the server becomes unresponsive.
  • HTTP 502/504 responses from the reverse proxy fronting Ghost while the Node.js process remains alive.

Detection Strategies

  • Monitor the Ghost process event-loop lag and flag sustained lag above a tuned threshold as a potential ReDoS condition.
  • Alert on administrator API calls to the external media inliner endpoint that are followed by abnormal CPU time on the same worker.
  • Correlate admin session activity with process-level resource spikes to identify a compromised or misused admin account.

Monitoring Recommendations

  • Track Ghost version strings in asset inventory and flag any instance running >= 5.37.0 and < 6.67.0.
  • Enable structured logging for the importer and inliner subsystems and ship logs to a central platform for retention and analysis.
  • Baseline normal CPU and request-latency patterns for Ghost workloads so anomalies tied to this issue become visible quickly.

How to Mitigate CVE-2026-105645

Immediate Actions Required

  • Upgrade Ghost to 6.67.0 or later, which is the fixed release line.
  • Review and rotate Administrator credentials and API keys, since exploitation requires admin privileges.
  • Restrict access to the Ghost admin interface to known IP ranges or an authenticated reverse proxy.

Patch Information

The fix is tracked in GitHub Security Advisory GHSA-9m4w-fmjw-fvjq and applied in commit 88ae6d6. Technical discussion is available in GitHub Issue #31058, and release notes for the preceding version are published at Ghost v6.66.0 release. Operators running self-hosted Ghost should pull the updated image or package and restart the service.

Workarounds

  • Temporarily disable or avoid using the external media inliner workflow until the patched version is deployed.
  • Enforce multi-factor authentication on all Ghost Administrator accounts to reduce the risk of unauthorized triggering.
  • Place Ghost behind a reverse proxy with request timeouts and per-admin rate limits to contain long-running inliner requests.
bash
# Upgrade self-hosted Ghost to the patched release
ghost update --version 6.67.0

# Verify installed version
ghost version

# Restrict admin access at the reverse proxy (nginx example)
# location /ghost/ {
#   allow 10.0.0.0/24;
#   deny all;
#   proxy_pass http://127.0.0.1:2368;
# }

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.