CVE-2026-27210
JSON

5.3medium

Pannellum has a XSS vulnerability in hot spot attributes

Severity
5.3medium CVSS:4.0 by GitHub_M
Exploit likelihood
0.45% (higher than 31% of CVEs)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-8423-w5wx-h2r6

Description

Pannellum is a lightweight, free, and open source panorama viewer for the web. In versions 3.5.0 through 2.5.6, the hot spot attributes configuration property allowed any attribute to be set, including HTML event handler attributes, allowing for potential XSS attacks. This affects websites hosting the standalone viewer HTML file and any other use of untrusted JSON config files (bypassing the protections of the escapeHTML parameter). As certain events fire without any additional user interaction, visiting a standalone viewer URL that points to a malicious config file — without additional user interaction — is sufficient to trigger the vulnerability and execute arbitrary JavaScript code, which can, for example, replace the contents of the page with arbitrary content and make it appear to be hosted by the website hosting the standalone viewer HTML file. This issue has been fixed in version 2.5.7. To workaround, setting the Content-Security-Policy header to script-src-attr 'none' will block execution of inline event handlers, mitigating this vulnerability. Don't host pannellum.htm on a domain that shares cookies with user authentication to mitigate XSS risk.

Affected

Product or packageVersionsReported by
mpetroff pannellum>= 2.5.0, < 2.5.7CVE List
pannellum (npm)from 2.5.0 before 2.5.7GitHub Advisory Database
pannellum pannellumfrom 2.5.0 before 2.5.7NVD

All scores

GitHub_M5.3medium CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
GitHubmedium CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
NVD6.1medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

Classification

CWE-79

SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.

What each source says

CVE List

Pannellum is a lightweight, free, and open source panorama viewer for the web. In versions 3.5.0 through 2.5.6, the hot spot attributes configuration property allowed any attribute to be set, including HTML event handler attributes, allowing for potential XSS attacks. This affects websites hosting the standalone viewer HTML file and any other use of untrusted JSON config files (bypassing the protections of the escapeHTML parameter). As certain events fire without any additional user interaction, visiting a standalone viewer URL that points to a malicious config file — without additional user interaction — is sufficient to trigger the vulnerability and execute arbitrary JavaScript code, which can, for example, replace the contents of the page with arbitrary content and make it appear to be hosted by the website hosting the standalone viewer HTML file. This issue has been fixed in version 2.5.7. To workaround, setting the Content-Security-Policy header to script-src-attr 'none' will block execution of inline event handlers, mitigating this vulnerability. Don't host pannellum.htm on a domain that shares cookies with user authentication to mitigate XSS risk.

GitHub Advisory Database
Impact

The hot spot attributes configuration property allowed any attribute to be set, including HTML event handler attributes, allowing for potential XSS attacks. This affects websites hosting the standalone viewer HTML file and any other use of untrusted JSON config files (bypassing the protections of the escapeHTML parameter). As certain events fire without any additional user interaction, visiting a standalone viewer URL that points to a malicious config file—without additional user interaction—is sufficient to trigger the vulnerability and execute arbitrary JavaScript code, which can, for example, replace the contents of the page with arbitrary content and make it appear to be hosted by the website hosting the standalone viewer HTML file.

Patches

This has been fixed both in v2.5.7 and in the current development branch.

Workarounds

Setting the Content-Security-Policy header to script-src-attr 'none' will block execution of inline event handlers, mitigating this vulnerability. Don't host pannellum.htm on a domain that shares cookies with user authentication to mitigate XSS risk.

Acknowledgments

Reported both by luminary (@lumin9ry), Visvge (@Sicclord1 / @Visvge), and sutol (@0x5a6163 / @SUT0L) and by another researcher who wishes not to be named at this time.

NVD (es)

Pannellum es un visor de panoramas ligero, gratuito y de código abierto para la web. En las versiones 3.5.0 a 2.5.6, la propiedad de configuración de atributos de punto de acceso permitía establecer cualquier atributo, incluyendo atributos de gestor de eventos HTML, lo que permitía posibles ataques XSS. Esto afecta a los sitios web que alojan el archivo HTML del visor independiente y a cualquier otro uso de archivos de configuración JSON no confiables (eludiendo las protecciones del parámetro escapeHTML). Como ciertos eventos se disparan sin ninguna interacción adicional del usuario, visitar una URL de visor independiente que apunte a un archivo de configuración malicioso — sin interacción adicional del usuario — es suficiente para activar la vulnerabilidad y ejecutar código JavaScript arbitrario, que puede, por ejemplo, reemplazar el contenido de la página con contenido arbitrario y hacer que parezca alojado por el sitio web que aloja el archivo HTML del visor independiente. Este problema ha sido solucionado en la versión 2.5.7. Como solución alternativa, establecer el encabezado Content-Security-Policy a 'script-src-attr 'none'' bloqueará la ejecución de gestores de eventos en línea, mitigando esta vulnerabilidad. No aloje pannellum.htm en un dominio que comparta cookies con la autenticación de usuario para mitigar el riesgo de XSS.

References

Sources

SourceRecordLicence
CVE ListCVE-2026-27210 changed 2026-02-25CVE Terms of Use
GitHub Advisory DatabaseGHSA-8423-w5wx-h2r6 changed 2026-02-23CC-BY-4.0
NVDCVE-2026-27210 changed 2026-06-17Public domain