CVE-2020-24303 Grafana XSS via a query alias for the ElasticSearch datasource
Attackers can execute arbitrary scripts in Grafana via malicious ElasticSearch query aliases, potentially compromising user sessions.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2020-24303?
CVE-2020-24303 is a medium-severity cross-site scripting vulnerability in Grafana Grafana, published on 28 Oct 2020. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
Grafana before 7.1.0-beta 1 allows XSS via a query alias for the ElasticSearch datasource.
Weakness: CWE-79
Which versions are affected by CVE-2020-24303?
4 open source packages ship an affected version, including github.com/grafana/grafana and grafana. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
github.com/grafana/grafana Go | All versions | None |
github.com/grafana/grafana Go | All versions | 7.1.0-beta1 |
github.com/grafana/grafana Go | All versions | 7.1.0-beta1 |
grafana Bitnami | All versions | 7.0.6 |
Products include Grafana Grafana.
How do I fix CVE-2020-24303?
Upgrade github.com/grafana/grafana to 7.1.0-beta1 or later.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2020-24303 being exploited?
There is no known exploitation of CVE-2020-24303 in the wild and no public exploit code.
Other vulnerabilities in Grafana Grafana
Sources
Also known as BIT-grafana-2020-24303, GHSA-mvpr-q6rh-8vrp, GO-2024-2520, MINI-5jwr-rw7q-jq6f, MINI-5p7p-rrxj-wcg2, MINI-7ggr-cmr7-94x5 and 15 more.