CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-53948

CVE-2026-53948: Stored Cross-Site Scripting via File Upload Content-Type Spoofing in Ghost

Alon Barad
Alon Barad
Software Engineer

Aug 5, 2026·6 min read·47 visits

Executive Summary (TL;DR)

Ghost versions 6.19.4 to 6.21.0 are vulnerable to Stored Cross-Site Scripting because they trust client-provided file MIME types during upload. Authenticated users can spoof content types to serve HTML scripts from cloud backends, compromising visitors and administrators. This issue is resolved in version 6.21.1.

CVE-2026-53948 is a stored cross-site scripting (XSS) vulnerability in the Ghost content management system. Affected versions (v6.19.4 up to v6.21.0) trusted the client-supplied Content-Type header during file uploads via the Admin API. This allowed authenticated attackers to upload benignly-named files with executable MIME types (like text/html), executing scripts in visitor browsers when hosted on integrated cloud platforms like S3 or GCS.

Vulnerability Overview

CVE-2026-53948 is a stored cross-site scripting (XSS) vulnerability in Ghost, an open-source content management system designed in Node.js. The vulnerability exists within the application's file upload subsystem accessed via the Admin API. Installations running versions 6.19.4 up to 6.21.0 are vulnerable to this security flaw.

Under normal operations, authorized users utilize the Admin API to upload static assets, such as images, PDFs, and documents. When configured with cloud storage backends like Amazon S3 or Google Cloud Storage, the system relies on stored metadata to determine how files are served to site visitors. Because the system trusted the user-supplied HTTP Content-Type header, attackers could map an arbitrary MIME type to a benign file extension.

The vulnerability is classified under CWE-434: Unrestricted Upload of File with Dangerous Type. Successful exploitation allows an authenticated attacker with minimal privileges to store malicious files that execute arbitrary script context within visitors' or administrators' web browsers. This compromise is particularly severe if the file is served from the same origin as the administrative dashboard.

Root Cause Analysis

The root cause of this vulnerability lies in the implicit trust of client-side inputs within Ghost's core server API code, specifically inside ghost/core/core/server/api/endpoints/files.js. During a file upload request via /ghost/api/admin/files/upload/, the client sends a multipart/form-data request containing the binary file and its metadata. Among these fields is the client-defined Content-Type header, which the backend reads as frame.file.mimetype.

The application server passed this user-controlled MIME type directly into the storage adapter configuration without server-side validation or sanitization. If the site is configured to store media locally, the impact is minimized because the web server typically determines the served mime-type based on the physical file extension. However, cloud storage adapters like Amazon S3 or Google Cloud Storage store the explicit metadata passed during the creation API call.

When a cloud adapter uploads the file, it registers the metadata containing the spoofed content type. The cloud platform later serves the file to the browser with the header specified during storage. Consequently, a request for a seemingly harmless file, such as report.pdf, results in the backend returning a response header of Content-Type: text/html if specified by the attacker.

Code Analysis

The vulnerable implementation in ghost/core/core/server/api/endpoints/files.js demonstrates how the server used the incoming mimetype variable directly. The type key in the storage options object received the raw, unvalidated frame.file.mimetype value from the request structure.

// Vulnerable Code Path
const filePath = await storage.getStorage('files').save({
    name: frame.file.originalname,
    path: frame.file.path,
    type: frame.file.mimetype // Directly trusts client input
});

The patch implemented in commit d659e752d6636144d75b9aa94062cdbc88a16b21 addresses this structural oversight by replacing the reference to frame.file.mimetype with a deterministic, server-determined MIME type. The system now loads the mime-types utility and uses it to parse the extension of the uploaded file's original name.

// Patched Code Path
const storage = require('../../adapters/storage');
const mime = require('mime-types');
 
const controller = {
    // ...
    const filePath = await storage.getStorage('files').save({
        name: frame.file.originalname,
        path: frame.file.path,
        type: mime.lookup(frame.file.originalname) || 'application/octet-stream'
    });

By querying the extension using mime.lookup(), the application guarantees that a file named image.png is registered and served as image/png regardless of what the user specified in the multipart request wrapper. If the extension is unrecognized, the code defaults to the safe fallback value of application/octet-stream, which prompts modern web browsers to download the resource instead of parsing or executing it natively.

Exploitation Scenario

Exploitation of CVE-2026-53948 requires an active account on the target Ghost CMS instance with privileges allowing file uploads, such as a Contributor, Author, or Editor. An attacker begins by crafting an HTML-compliant payload containing their malicious JavaScript. To bypass basic client-side verification or initial administrative inspection, the payload is given a legitimate extension, such as document.pdf or image.jpg.

The attacker then transmits an HTTP POST request targeting the /ghost/api/admin/files/upload/ endpoint using an intercepting proxy or a script. Within the multipart request, the attacker alters the Content-Type header linked to the uploaded file parts to text/html. The server receives the request, stores the binary content, and maps the attacker's text/html designation to the storage metadata registry.

When a victim navigates to the returned asset URL, the hosting bucket replies with the stored content-type rather than evaluating the file suffix. Because the returned header is text/html, the browser runs the embedded script under the target origin's context. This execution bypasses traditional boundaries, allowing access to standard web storage or session tokens.

Impact Assessment

The impact of a stored cross-site scripting vulnerability of this class is significant, particularly within content management systems. Because Ghost serves administrative actions and front-end visitor traffic from the same host by default, an active script payload executing on the main domain can interact directly with the Admin API on behalf of the victim.

If an administrative user is induced to view the uploaded file link, the executing script can perform actions with administrative permissions. This includes creating new admin users, altering system configurations, modifying published articles, or exfiltrating sensitive subscriber databases. For standard visitors, the script can be used to capture credentials via keystroke logging, redirect traffic to malicious domains, or deploy additional browser exploits.

The CVSS v3.1 score of 5.4 is calculated with a Low severity categorization due to the requirements for authentication (PR:L) and user interaction (UI:R). However, in environments where high-privileged users frequently review uploaded media from contributors, the real-world operational risk of administrative takeover is elevated. The impact scope is changed (S:C) because the attack crosses the storage-to-execution boundary within the browser sandbox.

Mitigation & Remediation Guidance

The primary remediation path is upgrading the Ghost installation to version 6.21.1 or later, which completely addresses the root cause of client-trusted MIME types. For installations where immediate upgrades are restricted due to operational deployment cycles, several mitigations should be implemented immediately to reduce exposure.

Administrators should configure their edge reverse proxies or CDNs to append the X-Content-Type-Options: nosniff header to all assets served from the /content/files/ directory. This header prevents modern web browsers from sniffing the content and forces them to align rendering decisions strictly with the declared file extension, neutralizing the HTML payload contained in the pseudo-image file.

Another highly effective defense-in-depth practice is the segregation of media hosting. By configuring the cloud storage adapter to serve files from a separate origin (e.g., ghost-assets.com instead of ghost-site.com), any script execution is restricted to the isolated sandbox domain. This prevents access to administrative sessions and cookies stored on the primary Ghost CMS host under the Same-Origin Policy.

Official Patches

TryGhostOfficial Security Advisory
TryGhostFix commit

Fix Analysis (1)

Technical Appendix

CVSS Score
5.4/ 10
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
EPSS Probability
0.13%
Top 97% most exploited

Affected Systems

Ghost CMS

Affected Versions Detail

Product
Affected Versions
Fixed Version
Ghost
TryGhost
>= 6.19.4, < 6.21.16.21.1
AttributeDetail
CWE IDCWE-434
Attack VectorNetwork
CVSS v3.1 Score5.4 (Medium)
Exploit StatusPoC Concept available
CISA KEV StatusNot listed
ImpactStored Cross-Site Scripting (XSS)

MITRE ATT&CK Mapping

T1059Command and Scripting Interpreter
Execution
T1105Ingress Tool Transfer
Command and Control
CWE-434
Unrestricted Upload of File with Dangerous Type

The product allows the attacker to upload or transfer files of dangerous types that can be automatically processed within the product's environment.

Vulnerability Timeline

Fix commit d659e752d6636144d75b9aa94062cdbc88a16b21 submitted and approved
2026-03-10
Public advisory GHSA-944x-pm95-3jpr published by Ghost
2026-06-24
CVE-2026-53948 published in CVE/NVD catalogs
2026-06-24

References & Sources

  • [1]Official Security Advisory
  • [2]GitHub Fix Commit
  • [3]GitHub Pull Request
  • [4]v6.21.1 Release Notes
  • [5]NVD Entry
  • [6]CVE Org Entry

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•17 minutes ago•GHSA-M3QR-FVP4-78XJ
5.3

GHSA-m3qr-fvp4-78xj: Authentication Bypass and Log Disclosure in Basekick Labs Arc

GHSA-m3qr-fvp4-78xj is an authentication bypass and information disclosure vulnerability in Arc, an open-source, SQL-native time-series database developed by Basekick Labs and written in Go. Due to an improper route registration sequence within the Go Fiber HTTP server initialization pipeline, the application registered the /api/v1/logs endpoint prior to mounting the global authentication middleware. Because Fiber evaluates route handlers in strict declaration order and terminates request traversal when a handler returns without invoking c.Next(), unauthenticated remote callers can query the logs endpoint and retrieve up to 10,000 buffered operational log entries even when authentication is enabled.

Alon Barad
Alon Barad
1 views•8 min read
•about 1 hour ago•CVE-2026-62848
7.3

CVE-2026-62848: Local Arbitrary Code Execution via Unsafe Deserialization in Metalama Named Pipe IPC

CVE-2026-62848 (GHSA-h26j-4vp7-x9w2) is a high-severity unsafe deserialization vulnerability in Metalama, a Roslyn-based meta-programming and code generation framework for C#. The flaw resides in the inter-process communication (IPC) channel used by Metalama within Microsoft Visual Studio. Across versions 2023.0 through 2026.1.18, the framework utilized either Newtonsoft.Json with TypeNameHandling.All or MessagePack with TypelessObjectResolver over local Windows named pipes without enforcing a strict type allow-list. Because the named pipes use predictable identifiers, any local process running under the same Windows user session can connect to the endpoint and transmit crafted serialized payloads, resulting in arbitrary Common Language Runtime (CLR) type instantiation and code execution within the host Visual Studio process.

Alon Barad
Alon Barad
5 views•9 min read
•about 2 hours ago•GHSA-9PPR-WFW9-XVR2
5.3

GHSA-9ppr-wfw9-xvr2: DNS Cache TTL Manipulation Failure in Netfoil via Go Value-Copy Range Iteration

A logic flaw in github.com/tinfoil-factory/netfoil versions 0.3.0 through 0.6.0 prevents the DNS proxy from properly decrementing Time-To-Live (TTL) values on cached DNS responses and enforcing configured maximum TTL limits. Due to an idiomatic Go programming mistake where a range loop modifies value copies of slice elements rather than the underlying slice array, netfoil continually serves DNS answers with their original static TTLs. This condition causes downstream clients and resolvers to retain stale DNS records beyond their intended expiration window and bypasses local MaxTTL administrative policies.

Alon Barad
Alon Barad
6 views•10 min read
•about 3 hours ago•CVE-2026-11800
8.1

CVE-2026-11800: Authentication Bypass via JWT Algorithm Confusion in Keycloak

A cryptographic signature verification flaw in Keycloak's OAuth 2.0 JWT Authorization Grant flow (RFC 7523) and federated client authentication mechanisms allows algorithm confusion between asymmetric and symmetric signing algorithms. Authenticated clients can sign forged JWT assertions using HMAC-SHA256 (HS256) with an Identity Provider's public key bytes acting as the symmetric secret. Keycloak processes the public key material as an HMAC secret key, validating the forged assertion and issuing unauthorized access tokens for federated users.

Alon Barad
Alon Barad
7 views•10 min read
•about 4 hours ago•CVE-2026-62331
8.2

CVE-2026-62331: Path Traversal and Stored Instruction Injection in Praktor Telegram File Uploads

CVE-2026-62331 is a high-severity path traversal vulnerability (CWE-22) affecting Praktor versions prior to 0.9.1. Praktor is a multi-agent Claude Code orchestrator that integrates Telegram message handling with isolated Docker container workspaces. Due to improper sanitization of user-controlled filenames during Telegram document uploads, a remote user can escape the designated uploads directory and overwrite arbitrary files within the persistent agent workspace volume. Because the default configuration permits messages from any Telegram user without authentication, an attacker can overwrite critical agent instruction files such as CLAUDE.md, achieving persistent prompt and instruction injection across subsequent agent executions.

Alon Barad
Alon Barad
5 views•9 min read
•about 5 hours ago•GHSA-P3JP-9V83-76W9
8.1

CVE-2026-111497 / GHSA-p3jp-9v83-76w9: Out-of-Bounds Heap Write in Microsoft .NET Brotli Decoder

CVE-2026-111497 (tracked as GHSA-p3jp-9v83-76w9) is an out-of-bounds heap write vulnerability in the native Google Brotli decompression library bundled within the Microsoft .NET runtime. The flaw occurs during the parsing of malformed block-switch sequences in compressed bitstreams when the fast execution path discards validation return statuses. Unauthenticated attackers delivering crafted Brotli payloads to applications configured to decompress untrusted streams can trigger memory corruption, resulting in denial of service, information disclosure, or arbitrary code execution.

Alon Barad
Alon Barad
5 views•11 min read