POC详情: 21afb06035fceeba5ec885e26dd06d17cfe82e1b

来源
关联漏洞
标题: Grafana 路径遍历漏洞 (CVE-2021-43798)
描述:Grafana是Grafana实验室的一套提供可视化监控界面的开源监控工具。该工具主要用于监控和分析Graphite、InfluxDB和Prometheus等。 Grafana 8.0.0-beta1至8.3.0存在路径遍历漏洞,攻击者可利用该漏洞执行目录遍历攻击,访问本地文件。
介绍
# Grafana CVE Scan 21-43798 0.1
#### Scanner for Grafana Path Traversal Vulnerability found in CVE-2021-43798

Disclaimer: This is for Educational Purposes only!

[![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](http://www.gnu.org/licenses/gpl-3.0)

## References for CVE:

  [1 - NIST CVE Details ](https://nvd.nist.gov/vuln/detail/CVE-2021-43798)

  [2 - Grafana Notes](https://grafana.com/blog/2021/12/07/grafana-8.3.1-8.2.7-8.1.8-and-8.0.7-released-with-high-severity-security-fix/)

## Workarounds

All installations between v8.0.0-beta1 and v8.3.0 should be upgraded as soon as possible.

If you cannot upgrade, running a reverse proxy in front of Grafana that normalizes the PATH of the request will mitigate the vulnerability. For example, the normalize_path setting in envoy.

Thanks to our defense-in-depth approach, Grafana Cloud instances have not been affected by the vulnerability.

As always, we closely coordinated with all cloud providers licensed to offer Grafana Pro. They have received early notification under embargo and confirmed that their offerings are secure at the time of this announcement. In alphabetical order, this is applicable to Amazon Managed Grafana and Azure Managed Grafana.

## Usage:

    $ grafana-CVE-2021-43798 [FLAGS] [OPTIONS]

## FLAGS:

    -c, --check      Just check for Vulnerability
        --help       Prints help information
    -n, --nossl      Use http:// instead https:// on URL
    -V, --version    Prints version information

## OPTIONS:

    -f, --file <file>                 File to be read on grafana server
    -H, --host <Host IP or domain>    Host IP or Domain and port e.g. 127.0.0.1:3000 to be checked for CVE
    -h, --hostlist <hostlist>         File containing a list of Hosts 1 per line with ip/domain:port e.g. 127.0.0.1:3000

## Installation

First you must install Rust package on your GNU/Linux distribution, MacOS ($$$$) or Windows (blergh!)

  https://www.rust-lang.org/tools/install

## Compiling 

It is really easy to compile. Just run :

    $ cargo build --release

Then you'll have the release ready in your <repo_downloaded_dir>/target/release/

That's all folks! Thank you very much.
文件快照

[4.0K] /data/pocs/21afb06035fceeba5ec885e26dd06d17cfe82e1b ├── [ 33K] Cargo.lock ├── [ 531] Cargo.toml ├── [ 30] ips.txt ├── [2.1K] README.md └── [4.0K] src ├── [3.4K] chkvuln.rs ├── [ 376] error.rs ├── [5.0K] main.rs └── [ 768] plugins.rs 1 directory, 8 files
神龙机器人已为您缓存
备注
    1. 建议优先通过来源进行访问。
    2. 如果因为来源失效或无法访问,请发送邮箱到 f.jinxu#gmail.com 索取本地快照(把 # 换成 @)。
    3. 神龙已为您对POC代码进行快照,为了长期维护,请考虑为本地POC付费,感谢您的支持。