---
id: "CVE-2026-18742"
page: "https://infrastack.ai/live/CVE-2026-18742"
kind: "vulnerability"
aliases: ["CVE-2026-18742"]
title: "Flatsome WordPress theme: contributors can inject scripts into pages"
severity: "medium"
cvss: 6.4
epss: null
exploited: false
status: "open"
category: "package"
products: [{"name": "Flatsome", "fixed": [], "affected": "", "ecosystem": "vendor"}]
ecosystems: ["vendor"]
tags: ["flatsome", "package", "self-hosted", "wordpress"]
not_affected_if: ["no-flatsome-theme", "only-trusted-editors"]
published_at: "2026-11-14T09:16:47+00:00"
first_seen_at: "2026-11-14T09:27:18+00:00"
updated_at: "2026-11-14T09:28:15+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-18742", "first_seen_at": "2026-11-14T09:27:18+00:00"}]
exploit_sources: []
---

# Flatsome WordPress theme: contributors can inject scripts into pages

Link for people: https://infrastack.ai/live/CVE-2026-18742 (this .md is for agents)

The Flatsome theme for WordPress lets a contributor-level user store script code inside a Custom HTML block through certain attributes. The script runs in the browser of any visitor who opens the affected page.

_Summary, check and fix written by a model from the sources; labelled as such._

## Affected

- vendor:Flatsome affected range not listed fixed no fixed version listed

## How to check

- Check the installed Flatsome version in the theme stylesheet header or Appearance > Themes; versions up to and including `3.20.12` are affected.
- Review pages with Custom HTML blocks that contain `data-text-sec`, `data-title` or `title` attributes with script-like content.

## Fix

- Flatsome: move to a version later than `3.20.12`; the sources do not name the fixed version.

## Timeline

- 2026-11-14T09:27:18+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-18742

## From the sources

The Flatsome theme for WordPress is vulnerable to Stored Cross-Site Scripting via 'data-text-sec', 'data-title', and 'title' Attributes via Custom HTML Block in all versions up to, and including, 3.20.12 due to insufficient input sanitization and output escaping. This makes it possible for authenticated attackers, with contributor-level access and above, to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page. The payload survives server-side sanitization because wp_kses_post permits data-* attributes globally via _wp_add_global_attributes, allowing attacker-controlled values in data-text-sec, data-title, and title attributes to persist in saved post content and be later interpreted as HTML by the ux-countdown, scroll-to, and lightbox-gallery JavaScript behaviors.

---

_Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai_
