POC详情: bd65babd9fa1a69932e546b31d3c431f363e80b7

来源
关联漏洞
标题: Apache Struts 2 输入验证错误漏洞 (CVE-2017-5638)
描述:Apache Struts是美国阿帕奇(Apache)软件基金会的一个开源项目,是一套用于创建企业级Java Web应用的开源MVC框架,主要提供两个版本框架产品,Struts 1和Struts 2。 Apache Struts 2 2.3.32之前的2 2.3.x版本和2.5.10.1之前的2.5.x版本中的Jakarta Multipart解析器存在安全漏洞,该漏洞源于程序没有正确处理文件上传。远程攻击者可借助带有#cmd=字符串的特制Content-Type HTTP头利用该漏洞执行任意命令。
介绍
# CVE-2017-5638

## Table of Contents
1. [Overview](#section-features)
2. [Dependencies](#section-dependencies)
3. [Usage](#section-usage)

## [Overview](id:section-featuers)

This project is a prove-of-concept for the Apache Struts vulnerabilty.
The goal was to create software that can generate and test random IPs for the vulnerabilty described above.


Use this project on your own risk and for educational purpose only.

## [Dependencies](id:section:dependencies)

* cURL
  * cURL is used to send the crafted header to a certain IP address on a certain Port.
  
* Nmap
  * Nmap is used to create the random IP addresses that contains an open port 80 or 443.

## [Usage](id:section-usage)

**Generate random IPs and save them to a text file.**
```bash
./get_ip.sh [Number of hosts to scan] [What port to scan] [Filename to write output]
```

```bash
./get_ip.sh 10000 80 output.txt
```

**Check for vulnerability for a specific IP address.**
```bash
./struts_check.sh [ip address] [port]
```

```bash
./struts_check.sh 127.0.0.1 80
```

**Check for vulnerability for a list of IP addresses.**
```bash
./main.sh [Text file containing IP adresses] [Port]
```

```bash
./main.sh output.txt 443
```

**Execute a command on a server without the Apache struts vulnerability patch**
```bash
./struts_attack.sh [IP Adres] [Command]
```

```bash
./struts_attack.sh https://127.0.0.1 whoami
```
文件快照

[4.0K] /data/pocs/bd65babd9fa1a69932e546b31d3c431f363e80b7 ├── [1.4K] README.md └── [4.0K] src ├── [ 965] get_ip.sh ├── [1.5K] main.sh ├── [1.4K] struts_attack.sh └── [1.9K] struts_check.sh 1 directory, 5 files
神龙机器人已为您缓存
备注
    1. 建议优先通过来源进行访问。
    2. 如果因为来源失效或无法访问,请发送邮箱到 f.jinxu#gmail.com 索取本地快照(把 # 换成 @)。
    3. 神龙已为您对POC代码进行快照,为了长期维护,请考虑为本地POC付费,感谢您的支持。