CVE-2026-33889 ApostropheCMS: Stored XSS via CSS Custom Property Injection in `@apostrophecms/color-field` Escaping Style Tag Context

Medium 5.4 Published Updated

An editor can inject JavaScript via CSS custom properties in the color field, leading to stored XSS and potential admin account takeover for all visitors.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2026-33889?

CVE-2026-33889 is a medium-severity cross-site scripting vulnerability in apostrophecms apostrophe, published on 15 Apr 2026. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.

Official description

ApostropheCMS is an open-source Node.js content management system. Versions 4.28.0 and prior contain a stored cross-site scripting vulnerability in the @apostrophecms/color-field module, where color values prefixed with -- bypass TinyColor validation intended for CSS custom properties, and the launder.string() call performs only type coercion without stripping HTML metacharacters. These unsanitized values are then concatenated directly into <style> tags both in per-widget style elements rendered for all visitors and in the global stylesheet rendered for editors, with the output marked as safe HTML. An editor can inject a value which closes the style tag and executes arbitrary JavaScript in the browser of every visitor to any page containing the affected widget. This enables mass session hijacking, cookie theft, and privilege escalation to administrative control if an admin views draft content. This issue has been fixed in version 4.29.0.

Weakness: CWE-79

Which versions are affected by CVE-2026-33889?

2 open source packages ship an affected version, including apostrophe. It affects 1 product.

PackageAffectedFixed in
apostrophe npmAll versions4.29.0
apostrophe npmAll versions4.29.0

Products include Apostrophecms Apostrophecms.

How do I fix CVE-2026-33889?

Upgrade apostrophe to 4.29.0 or later.

Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.

Is CVE-2026-33889 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-33889 exists.

Sources

Also known as GHSA-97v6-998m-fp4g.

Is CVE-2026-33889 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free