From beb93db8ddf635b7aa7d6ba4abf675503f3b3884 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 17 Aug 2026 23:54:54 +0300 Subject: [PATCH] security(core): escape "<" in the res.expose script island (stored XSS via app name) The dashboard serialises the exposed countlyGlobal object into an inline ). The serialiser only neutralised the exact sequence "", but the HTML tokeniser also ends a script element at "", "" and other whitespace/slash spellings, so an application name containing one of those broke out of the script block. An app admin of a single app could store such a name; any global admin who then loaded the dashboard (which lists every app) executed the attacker's markup in their own session, escalating an app-admin account to global-admin control. Escape every "<" as < in both serialisation paths: string values (the primitive branch, replacing the exact-match ""/"