Improper Encoding or Escaping of Output Affecting apostrophe package, versions <4.30.0


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Improper Encoding or Escaping of Output vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-JS-APOSTROPHE-16759742
  • published21 May 2026
  • disclosed14 May 2026
  • creditMuhammadUwais

Introduced: 14 May 2026

NewCVE-2026-45011  (opens in a new tab)
CWE-116  (opens in a new tab)
CWE-79  (opens in a new tab)

How to fix?

Upgrade apostrophe to version 4.30.0 or higher.

Overview

apostrophe is a content management system (CMS) for Node.js. It supports in-context editing, schema-driven content types, flexible widgets and a great deal more. This module contains everything necessary to build a website with ApostropheCMS.

Affected versions of this package are vulnerable to Improper Encoding or Escaping of Output via the linkHref field handling. An attacker can execute arbitrary JavaScript by supplying a javascript: URL in an image widget's link URL field and having it rendered on the page. This affects users who can edit content and allows an attacker to run a script in viewers’ browsers, exposing session data and enabling unauthorized actions on the affected site.

Notes: While the vulnerability was reported for apostrophe, the fix indicates that launder and sanitize-html contained similar flaws which were addressed through improved sanitization

##Workarounds

  • Restrict who can edit or publish image widgets so untrusted users cannot set the Link to field to a javascript: URL; this prevents stored XSS from being published to pages viewed by others.

CVSS Base Scores

version 4.0
version 3.1