/

CVE-2026-104414

Severity:

HIGH RISK

(8.1)

Stored XSS (CWE-79) in Ghost oEmbed Photo Responses

CVE-2026-104414

Deferred

Vulnerability type

Category:

Stored Cross-Site Scripting

CWE:

CWE-79

Impact:

Script execution and staff session compromise

Severity:

HIGH RISK

(8.1)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

Ghost contains a stored cross-site scripting vulnerability in the handling of oEmbed photo responses, allowing untrusted scripts to be persisted through embedded content. When a malicious oEmbed response is accepted and rendered, the scripts may execute in the Ghost editor, published site, or newsletter emails, potentially compromising staff sessions.

Affected context

The vulnerability may affect Ghost deployments that accept externally hosted oEmbed photo responses and persist the resulting content. Risk increases when imported or embedded content is rendered in administrative editing views, published pages, or newsletter messages without sufficiently context-aware output encoding and sanitization.

Exploit preconditions

  • Attack surface: oEmbed photo response processing and content rendering
  • Required access: Ability to supply or cause ingestion of a malicious oEmbed photo URL or response
  • Trigger point: Processing or rendering of the stored embedded content in the editor, website, or newsletter output
  • Why exploitation is possible: Untrusted response data can be stored and later interpreted as active script rather than treated strictly as inert content

Why this happens

The underlying issue is insufficient validation and output encoding of untrusted oEmbed response data before it is stored and rendered. This creates a stored cross-site scripting condition mapped to CWE-79, where attacker-controlled content is interpreted as executable script in a browser context. The risk is amplified when the same content is rendered across multiple trust boundaries, including staff-facing interfaces and outbound communications.

Potential impact

  • Attackers may execute scripts in staff administrators' browser sessions
  • Session information or sensitive page data could be exposed
  • Administrative actions could be performed using a compromised session context
  • Published pages and newsletter content may be altered or used to distribute malicious content
  • Visitor or subscriber trust could be undermined

General mitigation guidance

Mitigation generally focuses on treating all externally sourced oEmbed data as untrusted and ensuring it cannot become executable content.

Common defensive patterns include:

  • Applying context-aware output encoding at every rendering destination
  • Sanitizing embedded markup with a restrictive, allowlisted policy
  • Validating oEmbed response fields against expected schemas and media types
  • Avoiding direct insertion of untrusted HTML into privileged or email-rendered contexts
  • Restricting administrative session privileges and using defense-in-depth browser policies such as Content Security Policy
  • Preserving safe handling rules when content is rendered in editors, websites, and newsletters

How teams detect issues like this

Organizations can identify similar risks through:

  • Static analysis rules for unsafe HTML insertion, template escaping bypasses, and direct rendering of oEmbed fields
  • Code review checks covering external content ingestion, persistence, and reuse across rendering contexts
  • Dynamic testing with benign script markers in oEmbed and other imported content
  • Content-security and sanitization policy enforcement for editor, site, and email rendering paths
  • Automated security review tools that flag untrusted data flows into browser-executable sinks

Sources

SourceLink
github.comgithub.com/TryGhost/Ghost/security/advisories/GHSA-v3xr-g6p2-fvgv
vulncheck.comvulncheck.com/advisories/ghost-from-2.5.0-before-6.64.0-stored-xss-via-oembed-photo-responses

Frequently asked

questions

It may be exploitable through application-controlled oEmbed processing when an attacker can cause a malicious response or URL to be imported and rendered. The exact scope depends on Ghost configuration, content permissions, and network access to the oEmbed source.

Not necessarily. The key requirement is the ability to influence content that Ghost accepts as an oEmbed photo response. The impact may be greater when staff members view the resulting content in the editor or administrative interface.

Treat oEmbed responses as untrusted, validate them against an allowlist, sanitize stored content, and apply context-aware output encoding before rendering it in every destination.

Enforce secure content-rendering policies, test external-content import paths, review all HTML insertion points, and use browser protections such as restrictive Content Security Policy where practical.

Find out what's already
exploitable in your codebase.