mirror of
https://github.com/Medicean/VulApps.git
synced 2025-06-02 11:40:46 +00:00
(Add Vul: Struts2) s2-015
This commit is contained in:
parent
96de675b09
commit
e63c87520a
14
s/struts2/s2-015/Dockerfile
Normal file
14
s/struts2/s2-015/Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
FROM tomcat:8-jre8
|
||||
MAINTAINER 0x0keeper@gmail.com
|
||||
|
||||
ENV WAR_URL http://ocnf2x3pk.bkt.clouddn.com/S2-015.war
|
||||
|
||||
WORKDIR /tmp
|
||||
|
||||
RUN set -ex \
|
||||
&& rm -rf /usr/local/tomcat/webapps/* \
|
||||
&& chmod a+x /usr/local/tomcat/bin/*.sh \
|
||||
&& wget -qO /usr/local/tomcat/webapps/ROOT.war $WAR_URL
|
||||
|
||||
EXPOSE 8080
|
||||
CMD ["/usr/local/tomcat/bin/catalina.sh", "run"]
|
51
s/struts2/s2-015/README.md
Normal file
51
s/struts2/s2-015/README.md
Normal file
@ -0,0 +1,51 @@
|
||||
## Struts2_Jakarta_Plugin插件远程代码执行漏洞(S2-046) 环境
|
||||
|
||||
### 漏洞信息
|
||||
|
||||
* [S2-046 公告](https://cwiki.apache.org/confluence/display/WW/S2-046)
|
||||
|
||||
### 获取环境:
|
||||
|
||||
1. 拉取镜像到本地
|
||||
|
||||
```
|
||||
$ docker pull medicean/vulapps:s_struts2_s2-046
|
||||
```
|
||||
|
||||
2. 启动环境
|
||||
|
||||
```
|
||||
$ docker run -d -p 80:8080 medicean/vulapps:s_struts2_s2-046
|
||||
```
|
||||
> `-p 80:8080` 前面的 80 代表物理机的端口,可随意指定。
|
||||
|
||||
### 使用与利用
|
||||
|
||||
访问 `http://你的 IP 地址:端口号/`
|
||||
|
||||
#### PoC
|
||||
|
||||
> 本例中使用 [Struts2_Jakarta_Plugin插件远程代码执行漏洞(S2-046) ](http://www.bugscan.net/source/plugin/4787/template/)
|
||||
|
||||
|
||||
1. 下载并安装 `BugScan SDK`
|
||||
|
||||
详见 [BugScan 插件开发文档 - 环境配置](http://doc.bugscan.net/chapter1/1-1.html)
|
||||
|
||||
2. 修改 `poc.py` 中地址为容器地址
|
||||
|
||||
> 该漏洞无需配合上传表单使用
|
||||
|
||||
```
|
||||
if __name__ == '__main__':
|
||||
from dummy import *
|
||||
audit(assign(fingerprint.struts, 'http://127.0.0.1:8080/')[1])
|
||||
|
||||
```
|
||||
|
||||
3. 运行 `poc.py`
|
||||
|
||||
```
|
||||
$ python poc.py
|
||||
```
|
||||
|
BIN
s/struts2/s2-015/s2-015-1.png
Normal file
BIN
s/struts2/s2-015/s2-015-1.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 18 KiB |
Loading…
x
Reference in New Issue
Block a user