Skip to content
OpenAdvisories
High · 7.3 CVE-2022-31097 BIT-grafana-2022-31097EUVD-2024-1819GHSA-vw7q-p2qg-4m5fGO-2024-2857

Stored XSS in Grafana's Unified Alerting

Published Jul 15, 2022 · Updated Jan 28, 2026 · Assigned by GitHub_M

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.

Affected products

VendorProductAffectedFixed
grafana grafana >= 9.0.0, < 9.0.3, >= 8.5.0, < 8.5.9, >= 8.4.0, < 8.4.10, >= 8.0.0, < 8.3.10 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Ubuntu 16.04 LTS grafana No fix yet —
ReleasePackageFixed inAdvisory
SLES 15 SP5 grafana 9.5.1-150200.3.41.3 SUSE-SU-2023:2575-1
SLES 15 SP4 grafana 8.3.10-150200.3.26.1 SUSE-SU-2023:2575-1, SUSE-SU-2022:4428-1, SUSE-SU-2022:3765-1
SLES 15 SP2 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SLES 15 SP1 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SLES 15 golang-github-prometheus-node_exporter 1.3.0-150000.3.18.1 SUSE-SU-2022:3751-1
Show 23 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SLES 12 SP5 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2022:3747-1
SLES 12 SP4 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2022:3747-1
SLES 12 SP3 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2022:3747-1
SLES for SAP 15 SP2 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SLES for SAP 15 SP1 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SLES for SAP 15 golang-github-prometheus-node_exporter 1.3.0-150000.3.18.1 SUSE-SU-2022:3751-1
SLES for SAP 12 SP5 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2022:3747-1
SLES for SAP 12 SP4 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2022:3747-1
SLE HPC 15 SP2 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SLE HPC 15 SP1 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SLE HPC 15 golang-github-prometheus-node_exporter 1.3.0-150000.3.18.1 SUSE-SU-2022:3751-1
SUSE OpenStack Cloud Crowbar 9 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2022:3747-1
SUSE OpenStack Cloud 9 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2022:3747-1
SUSE Manager Server Module 4.3 golang-github-lusitaniae-apache_exporter 0.11.0-150000.1.12.1 SUSE-SU-2022:3751-1
SUSE Manager Server Module 4.2 golang-github-lusitaniae-apache_exporter 0.11.0-150000.1.12.1 SUSE-SU-2022:3751-1
SUSE Manager Proxy Module 4.3 golang-github-boynux-squid_exporter 1.6-150000.1.9.1 SUSE-SU-2022:4437-1
SUSE Manager Proxy Module 4.3 golang-github-lusitaniae-apache_exporter 0.11.0-150000.1.12.1 SUSE-SU-2022:3751-1
SUSE Manager Proxy Module 4.3 prometheus-blackbox_exporter 0.19.0-150000.1.14.3 SUSE-SU-2022:4437-1
SUSE Manager Proxy Module 4.3 zypp-plugin-spacewalk 1.0.14-150000.3.35.1 SUSE-SU-2023:2578-1
SUSE Manager Proxy Module 4.2 golang-github-boynux-squid_exporter 1.6-150000.1.9.1 SUSE-SU-2022:4437-1
SUSE Manager Proxy Module 4.2 golang-github-lusitaniae-apache_exporter 0.11.0-150000.1.12.1 SUSE-SU-2022:3751-1
SUSE Manager Proxy Module 4.2 prometheus-blackbox_exporter 0.19.0-150000.1.14.3 SUSE-SU-2022:4437-1
SUSE Manager Proxy Module 4.2 zypp-plugin-spacewalk 1.0.14-150000.3.35.1 SUSE-SU-2023:2578-1
SUSE Manager Client Tools for SLE Micro 5 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SUSE Manager Client Tools for SLE Micro 5 dracut-saltboot 0.1.1665997480.587fa10-150000.1.41.1 SUSE-SU-2023:2578-1, SUSE-SU-2022:4437-1
SUSE Manager Client Tools for SLE Micro 5 prometheus-blackbox_exporter 0.19.0-150000.1.14.3 SUSE-SU-2022:4437-1
SUSE Manager Client Tools for SLE Micro 5 uyuni-proxy-systemd-services 4.3.7-150000.1.9.3 SUSE-SU-2022:4437-1
SUSE Manager Client Tools Beta for SLE Micro 5 dracut-saltboot 0.1.1681904360.84ef141-159000.3.30.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools Beta for SLE Micro 5 golang-github-QubitProducts-exporter_exporter 0.4.0-159000.4.6.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools Beta for SLE Micro 5 prometheus-blackbox_exporter 0.24.0-159000.3.6.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools Beta for SLE Micro 5 uyuni-proxy-systemd-services 5.0.1-159000.3.9.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 ansible 2.9.27-159000.3.9.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 dracut-saltboot 0.1.1661440542.6cbe0da-150000.1.38.1 SUSE-SU-2024:0196-1, SUSE-SU-2023:2578-1, SUSE-SU-2022:4437-1
SUSE Manager Client Tools 15 golang-github-QubitProducts-exporter_exporter 0.4.0-159000.4.6.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 golang-github-boynux-squid_exporter 1.6-150000.1.9.1 SUSE-SU-2024:0196-1, SUSE-SU-2022:4437-1
SUSE Manager Client Tools 15 golang-github-lusitaniae-apache_exporter 0.11.0-150000.1.12.1 SUSE-SU-2024:0196-1, SUSE-SU-2022:3751-1
SUSE Manager Client Tools 15 golang-github-prometheus-prometheus 2.45.0-159000.6.33.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 grafana 8.3.10-150000.1.33.1 SUSE-SU-2024:0196-1, SUSE-SU-2023:2578-1, SUSE-SU-2022:4437-1
SUSE Manager Client Tools 15 mgr-daemon 4.3.6-150000.1.38.1 SUSE-SU-2023:2578-1, SUSE-SU-2022:3751-1
SUSE Manager Client Tools 15 mgr-push 5.0.1-159000.4.21.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 prometheus-blackbox_exporter 0.19.0-150000.1.14.3 SUSE-SU-2024:0196-1, SUSE-SU-2022:4437-1
SUSE Manager Client Tools 15 prometheus-postgres_exporter 0.10.1-159000.3.6.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 python-hwdata 2.3.5-159000.5.13.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 python-pyvmomi 6.7.3-159000.3.6.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 rhnlib 5.0.1-159000.6.30.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 spacecmd 4.3.15-150000.3.86.1 SUSE-SU-2024:0196-1, SUSE-SU-2023:2578-1, SUSE-SU-2022:4437-1
SUSE Manager Client Tools 15 spacewalk-client-tools 4.3.12-150000.3.68.2 SUSE-SU-2024:0196-1, SUSE-SU-2022:4437-1, SUSE-SU-2022:3751-1
SUSE Manager Client Tools 15 supportutils-plugin-salt 1.2.2-159000.5.9.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 supportutils-plugin-susemanager-client 5.0.1-159000.6.15.1 SUSE-SU-2024:0196-1
SUSE Manager Client Tools 15 uyuni-common-libs 4.3.6-150000.1.27.2 SUSE-SU-2024:0196-1, SUSE-SU-2023:2578-1, SUSE-SU-2022:3751-1
SUSE Manager Client Tools 15 uyuni-proxy-systemd-services 4.3.7-150000.1.9.3 SUSE-SU-2024:0196-1, SUSE-SU-2022:4437-1
SUSE Manager Client Tools 15 zypp-plugin-spacewalk 1.0.14-150000.3.35.1 SUSE-SU-2023:2578-1
SUSE Manager Client Tools 12 golang-github-QubitProducts-exporter_exporter 0.4.0-4.6.2 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 golang-github-boynux-squid_exporter 1.6-1.9.1 SUSE-SU-2024:0191-1, SUSE-SU-2022:4439-1
SUSE Manager Client Tools 12 golang-github-lusitaniae-apache_exporter 0.11.0-1.13.1 SUSE-SU-2024:0191-1, SUSE-SU-2022:3747-1
SUSE Manager Client Tools 12 golang-github-prometheus-alertmanager 0.23.0-1.15.2 SUSE-SU-2024:0191-1, SUSE-SU-2022:3747-1
SUSE Manager Client Tools 12 golang-github-prometheus-node_exporter 1.3.0-1.21.1 SUSE-SU-2024:0191-1, SUSE-SU-2022:3747-1
SUSE Manager Client Tools 12 golang-github-prometheus-prometheus 2.45.0-4.33.3 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 golang-github-prometheus-promu 0.14.0-4.12.2 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 grafana 8.3.10-1.33.2 SUSE-SU-2024:0191-1, SUSE-SU-2023:2579-1, SUSE-SU-2022:4439-1
SUSE Manager Client Tools 12 kiwi-desc-saltboot 0.1.1661440542.6cbe0da-1.29.1 SUSE-SU-2024:0191-1, SUSE-SU-2022:3747-1
SUSE Manager Client Tools 12 mgr-daemon 4.3.6-1.38.1 SUSE-SU-2023:2579-1, SUSE-SU-2022:3747-1
SUSE Manager Client Tools 12 mgr-push 5.0.1-4.21.4 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 prometheus-blackbox_exporter 0.19.0-1.14.1 SUSE-SU-2024:0191-1, SUSE-SU-2022:4439-1
SUSE Manager Client Tools 12 prometheus-postgres_exporter 0.10.1-3.6.4 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 python-hwdata 2.3.5-15.12.2 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 rhnlib 5.0.1-24.30.3 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 spacecmd 4.3.15-38.109.1 SUSE-SU-2024:0191-1, SUSE-SU-2023:2579-1, SUSE-SU-2022:4439-1
SUSE Manager Client Tools 12 spacewalk-client-tools 4.3.12-52.77.1 SUSE-SU-2022:4439-1, SUSE-SU-2022:3747-1
SUSE Manager Client Tools 12 supportutils-plugin-salt 1.2.2-9.9.2 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 supportutils-plugin-susemanager-client 5.0.1-9.15.2 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 system-user-grafana +1 1.0.0-3.7.2 SUSE-SU-2024:0191-1
SUSE Manager Client Tools 12 uyuni-common-libs 4.3.6-1.27.1 SUSE-SU-2024:0191-1, SUSE-SU-2023:2579-1, SUSE-SU-2022:3747-1
SUSE Manager Client Tools 12 zypp-plugin-spacewalk 1.0.14-30.42.1 SUSE-SU-2023:2579-1
SUSE Enterprise Storage 7 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
SUSE Enterprise Storage 6 grafana 8.5.13-150100.3.12.1 SUSE-SU-2022:3676-1
ReleasePackageFixed inAdvisory
openSUSE Tumbleweed grafana 8.3.10-1.1 openSUSE-SU-2024:12260-1
openSUSE Leap 15.5 dracut-saltboot 0.1.1681904360.84ef141-150000.1.50.1 SUSE-SU-2023:2578-1
openSUSE Leap 15.5 grafana 9.5.1-150200.3.41.3 SUSE-SU-2023:2575-1
openSUSE Leap 15.5 spacecmd 4.3.21-150000.3.98.1 SUSE-SU-2023:2578-1
openSUSE Leap 15.5 wire 0.5.0-150000.1.12.3 SUSE-SU-2023:2578-1
openSUSE Leap 15.4 bind 9.16.6-150000.12.65.1 SUSE-SU-2023:2578-1
openSUSE Leap 15.4 dracut-saltboot 0.1.1661440542.6cbe0da-150000.1.38.1 SUSE-SU-2023:2578-1, SUSE-SU-2022:4437-1, SUSE-SU-2022:3751-1
openSUSE Leap 15.4 golang-github-boynux-squid_exporter 1.6-150000.1.9.1 SUSE-SU-2022:4437-1
openSUSE Leap 15.4 golang-github-lusitaniae-apache_exporter 0.11.0-150000.1.12.1 SUSE-SU-2022:3751-1
openSUSE Leap 15.4 golang-github-prometheus-promu 0.13.0-150000.3.9.1 SUSE-SU-2022:4437-1
openSUSE Leap 15.4 grafana 8.3.10-150200.3.26.1 SUSE-SU-2023:2575-1, SUSE-SU-2022:4428-1, SUSE-SU-2022:3765-1
openSUSE Leap 15.4 prometheus-blackbox_exporter 0.19.0-150000.1.14.3 SUSE-SU-2022:4437-1
openSUSE Leap 15.4 spacecmd 4.3.15-150000.3.86.1 SUSE-SU-2023:2578-1, SUSE-SU-2022:4437-1, SUSE-SU-2022:3751-1
openSUSE Leap 15.4 wire 0.5.0-150000.1.9.3 SUSE-SU-2023:2578-1, SUSE-SU-2022:4437-1
openSUSE Leap 15.3 dracut-saltboot 0.1.1661440542.6cbe0da-150000.1.38.1 SUSE-SU-2022:4437-1, SUSE-SU-2022:3751-1
openSUSE Leap 15.3 golang-github-boynux-squid_exporter 1.6-150000.1.9.1 SUSE-SU-2022:4437-1
openSUSE Leap 15.3 golang-github-lusitaniae-apache_exporter 0.11.0-150000.1.12.1 SUSE-SU-2022:3751-1
openSUSE Leap 15.3 golang-github-prometheus-promu 0.13.0-150000.3.9.1 SUSE-SU-2022:4437-1
openSUSE Leap 15.3 grafana 8.3.10-150200.3.26.1 SUSE-SU-2022:4428-1, SUSE-SU-2022:3765-1
openSUSE Leap 15.3 spacecmd 4.3.15-150000.3.86.1 SUSE-SU-2022:4437-1, SUSE-SU-2022:3751-1
ReleasePackageFixed inAdvisory
Alpine v3.24 grafana 9.0.3-r0 —
Alpine v3.23 grafana 9.0.3-r0 —
Alpine v3.22 grafana 9.0.3-r0 —
Alpine v3.21 grafana 9.0.3-r0 —
Alpine v3.20 grafana 9.0.3-r0 —
Show 4 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Alpine v3.19 grafana 9.0.3-r0 —
Alpine v3.18 grafana 9.0.3-r0 —
Alpine v3.17 grafana 9.0.3-r0 —
Alpine v3.16 grafana 8.5.9-r0 —

Affected packages

EcosystemPackageAffectedFixedRecord
Go github.com/grafana/grafana >= 9.0.0, < 9.0.3 9.0.3 GHSA-vw7q-p2qg-4m5f
Go github.com/grafana/grafana >= 8.5.0, < 8.5.9 8.5.9 GHSA-vw7q-p2qg-4m5f
Go github.com/grafana/grafana >= 8.4.0, < 8.4.10 8.4.10 GHSA-vw7q-p2qg-4m5f
Go github.com/grafana/grafana >= 8.0.0, < 8.3.10 8.3.10 GHSA-vw7q-p2qg-4m5f
Go github.com/grafana/grafana all versions — GO-2024-2857

Advisories 15

References