CVE-2022-23552: Grafana: stored XSS in GeoMap SVG enables admin takeover

HIGH
Published January 27, 2023
CISO Take

Grafana's GeoMap panel failed to sanitize SVG files, so an Editor-role user can plant JavaScript that runs in the browser of anyone viewing the dashboard, including Admins, and can be used to reset an Admin's password. This is a monitoring and observability platform that commonly sits next to ML pipelines, model-serving metrics and training dashboards, so an Admin takeover exposes data sources, credentials and operational telemetry for AI workloads. Exploitation likelihood looks low to moderate: it is not in CISA KEV, no public exploit or Nuclei template is known, and EPSS data is unavailable. The attack still needs an authenticated Editor and a victim who views the dashboard. Upgrade to Grafana 8.5.16, 9.2.10 or 9.3.4 or later, and review who holds Editor rights on instances that monitor AI/ML infrastructure.

Sources:NVDGitHub AdvisoryATLAS

What is the risk?

High severity (CVSS 7.3) but constrained by preconditions. The attacker needs low privileges (Editor role) and user interaction from the victim, so it is not exploitable by anonymous internet users. Impact on confidentiality and integrity is high, because vertical privilege escalation to Admin is possible. There is no known active exploitation, no KEV listing, and no public exploit or scanner template. Risk is highest in multi-tenant or shared Grafana instances where many users hold Editor rights, and where dashboards cover ML platform telemetry.

How does the attack unfold?

Initial Access
Attacker uses a valid Editor account on the Grafana instance.
AML.T0012
Payload Planting
Attacker edits a GeoMap panel to load an external or data: SVG containing JavaScript.
Privilege Escalation
An Admin views the dashboard and the script changes the Admin's password to an attacker-known value.
Impact
Attacker accesses Admin functions, data source credentials and ML monitoring data, and can alter alerts.
AML.T0049

What systems are affected?

PackageEcosystemVulnerable RangePatched
grafana——No patch

Do you use grafana? You're affected.

How severe is it?

CVSS 3.1
7.3 / 10
EPSS
N/A
Exploitation Status
No known exploitation
Sophistication
Trivial

What is the attack surface?

AVACPRUISCIA
AVNetwork
ACLow
PRLow
UIRequired
SUnchanged
CHigh
IHigh
ANone

What should I do?

1 step
  1. 1) Upgrade Grafana to 8.5.16, 9.2.10, 9.3.4 or later. 2) Until patched, restrict the Editor role to trusted users and audit current Editor and Admin assignments. 3) Review existing GeoMap panels for external SVG URLs or data: scheme references pointing to untrusted content. 4) Enforce a strict Content-Security-Policy that limits script sources and blocks inline scripts where possible. 5) Monitor Grafana audit logs for unexpected panel edits, password changes and user role changes on Admin accounts. 6) Rotate data source credentials stored in Grafana if compromise of an Admin session is suspected.

How is it classified?

Which compliance frameworks are affected?

This CVE is relevant to:

ISO 42001
A.6.2.6-AI system operation and monitoring
NIST AI RMF
MANAGE 2.3-Respond to and recover from previously unknown risks

Frequently Asked Questions

What is CVE-2022-23552?

Grafana's GeoMap panel failed to sanitize SVG files, so an Editor-role user can plant JavaScript that runs in the browser of anyone viewing the dashboard, including Admins, and can be used to reset an Admin's password. This is a monitoring and observability platform that commonly sits next to ML pipelines, model-serving metrics and training dashboards, so an Admin takeover exposes data sources, credentials and operational telemetry for AI workloads. Exploitation likelihood looks low to moderate: it is not in CISA KEV, no public exploit or Nuclei template is known, and EPSS data is unavailable. The attack still needs an authenticated Editor and a victim who views the dashboard. Upgrade to Grafana 8.5.16, 9.2.10 or 9.3.4 or later, and review who holds Editor rights on instances that monitor AI/ML infrastructure.

Is CVE-2022-23552 actively exploited?

No confirmed active exploitation of CVE-2022-23552 has been reported, but organizations should still patch proactively.

How to fix CVE-2022-23552?

1) Upgrade Grafana to 8.5.16, 9.2.10, 9.3.4 or later. 2) Until patched, restrict the Editor role to trusted users and audit current Editor and Admin assignments. 3) Review existing GeoMap panels for external SVG URLs or data: scheme references pointing to untrusted content. 4) Enforce a strict Content-Security-Policy that limits script sources and blocks inline scripts where possible. 5) Monitor Grafana audit logs for unexpected panel edits, password changes and user role changes on Admin accounts. 6) Rotate data source credentials stored in Grafana if compromise of an Admin session is suspected.

What systems are affected by CVE-2022-23552?

This vulnerability affects the following AI/ML architecture patterns: ML monitoring and observability dashboards, Model serving telemetry, Training pipeline monitoring, MLOps platforms.

What is the CVSS score for CVE-2022-23552?

CVE-2022-23552 has a CVSS v3.1 base score of 7.3 (HIGH).

What is the AI security impact?

Affected AI Architectures

ML monitoring and observability dashboardsModel serving telemetryTraining pipeline monitoringMLOps platforms

MITRE ATLAS Techniques

AML.T0012Valid Accounts
AML.T0049Exploit Public-Facing Application

Compliance Controls Affected

ISO 42001: A.6.2.6
NIST AI RMF: MANAGE 2.3

What are the technical details?

Original Advisory

Grafana is an open-source platform for monitoring and observability. Starting with the 8.1 branch and prior to versions 8.5.16, 9.2.10, and 9.3.4, Grafana had a stored XSS vulnerability affecting the core plugin GeoMap. The stored XSS vulnerability was possible because SVG files weren't properly sanitized and allowed arbitrary JavaScript to be executed in the context of the currently authorized user of the Grafana instance. An attacker needs to have the Editor role in order to change a panel to include either an external URL to a SVG-file containing JavaScript, or use the `data:` scheme to load an inline SVG-file containing JavaScript. This means that vertical privilege escalation is possible, where a user with Editor role can change to a known password for a user having Admin role if the user with Admin role executes malicious JavaScript viewing a dashboard. Users may upgrade to version 8.5.16, 9.2.10, or 9.3.4 to receive a fix.

Exploitation Scenario

An attacker with an Editor account on a shared Grafana instance that monitors an ML platform edits a GeoMap panel on a widely viewed inference-monitoring dashboard. They point the SVG marker to an external URL or a data: URI containing JavaScript. When an Admin opens the dashboard, the script runs in the Admin's session and calls the Grafana API to change the Admin's password to a value the attacker knows. The attacker logs in as Admin, reads data source configurations and credentials for ML metrics stores, and modifies alert rules to suppress detection.

Weaknesses (CWE)

CWE-79 — Improper Neutralization of Input During Web Page Generation: The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.

  • [Architecture and Design] Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid [REF-1482]. Examples of libraries and frameworks that make it easier to generate properly encoded output include Microsoft's Anti-XSS library, the OWASP ESAPI Encoding module, and Apache Wicket.
  • [Implementation, Architecture and Design] Understand the context in which your data will be used and the encoding that will be expected. This is especially important when transmitting data between different components, or when generating outputs that can contain multiple encodings at the same time, such as web pages or multi-part mail messages. Study all expected communication protocols and data representations to determine the required encoding strategies. For any data that will be output to another web page, especially any data that was received from external inputs, use the appropriate encoding on all non-alphanumeric characters. Parts of the same output document may require different encodings, which will vary depending on whether the output is in the: etc. Note that HTML Entity Encoding is only appropriate for the HTML body. Consult the XSS Prevention Cheat Sheet [REF-724] for more details on the types of encoding and escaping that are needed. HTML body Element attributes (such as src="XYZ") URIs JavaScript sections Casca

Source: MITRE CWE corpus.

CVSS Vector

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:N

Timeline

Published
January 27, 2023
Last Modified
November 3, 2026
First Seen
November 4, 2026

Related Vulnerabilities