POC详情: 18a99aa0c4517e73a4676af16b596e6d0cb4d78f

来源
关联漏洞
标题: Ollama 安全漏洞 (CVE-2024-37032)
描述:Ollama是Ollama开源的一个可以在本地启动并运行的大型语言模型。 Ollama 0.1.34之前版本存在安全漏洞,该漏洞源于在获取模型路径时不验证摘要的格式,会错误处理测试用例。
描述
Path traversal in Ollama with rogue registry server
介绍
# CVE-2024-37032
Path traversal in Ollama with rogue registry server

- Learn from [Probllama: Ollama Remote Code Execution Vulnerability (CVE-2024-37032) – Overview and Mitigations](https://www.wiz.io/blog/probllama-ollama-vulnerability-cve-2024-37032#the-vulnerability-arbitrary-file-write-via-path-traversal-25)

# Vulnerability environment

```bash
docker run -d -v ollama:/root/.ollama -p 11434:11434 --name ollama ollama/ollama:0.1.33
```

# Rogue registry server

- Please modify `HOST` to your host **MUST WITHOUT PORT**
- Run with `python3 server.py`

# Run poc

- Please modify `HOST` to your rogue registry server host, and `target_url` to vulnerability host
- Run `python3 poc.py` and check rogue registry server log

![](screenshot.png)
文件快照

[4.0K] /data/pocs/18a99aa0c4517e73a4676af16b596e6d0cb4d78f ├── [1.0K] LICENSE ├── [ 372] poc.py ├── [ 751] README.md ├── [ 48] requirements.txt ├── [4.0K] rogue_registry_server │   └── [5.2K] server.py └── [335K] screenshot.png 1 directory, 6 files
神龙机器人已为您缓存
备注
    1. 建议优先通过来源进行访问。
    2. 如果因为来源失效或无法访问,请发送邮箱到 f.jinxu#gmail.com 索取本地快照(把 # 换成 @)。
    3. 神龙已为您对POC代码进行快照,为了长期维护,请考虑为本地POC付费,感谢您的支持。