Bug 1661437 (CVE-2018-1000816)

Summary: CVE-2018-1000816 grafana: Cross site scripting in Influxdb and Graphite query editor
Product: [Other] Security Response Reporter: Andrej Nemec <anemec>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: ahardin, bleanhar, ccoleman, dedgar, eparis, jgoulding, jjoyce, jokerman, jschluet, lhh, lpeer, mburns, mchappel, mmagr, sclewis, sisharma, slinaber
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: grafana 5.3.2 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-10-27 03:19:48 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1662428, 1662429, 1662430, 1673076    
Bug Blocks: 1661438    

Description Andrej Nemec 2018-12-21 09:17:05 UTC
A persistent XSS vulnerability was found in in Influxdb and Graphite query editor of Grafana before 5.3.2.

Upstream issues:

https://github.com/grafana/grafana/issues/13667
https://github.com/grafana/grafana/pull/13670

Comment 4 Hardik Vyas 2019-01-03 12:46:26 UTC
Ceph and Gluster both storage products are affected to this Cross site scripting vulnerability. For instance, an attacker can inject URL in the query editor part and upon clicking the field in the query editor this can redirect to the vulnerable site. Issue can be reproduced with the below payload where clicking the query editor field will open a new tab for redhat.com

   "<script>window.open("https://www.redhat.com/")</script>

Comment 6 Hardik Vyas 2019-01-03 13:03:30 UTC
Statement:

The version of Grafana provided in Red Hat OpenStack Optools does not contain the vulnerable functionality and is not affected by this vulnerability. Additionally, Grafana is unsupported in Red Hat OpenStack.
Grafana shipped with Ceph and Gluster includes the affected code, and is vulnerable to cross site scripting attack via query editor.