Sploitus

Exploit for Expression Language Injection in Apache Struts

githubexploit · 2022-04-15

Exploit Code

README19 lines
## https://sploitus.com/exploit?id=54A96A93-E5F5-564A-9827-807A288EEF92
# CVE-2021-31805
## Remote code execution S2-062 (CVE-2021-31805) Due to Apache Struts2's incomplete fix for S2-061 (CVE-2020-17530), some tag attributes can still execute OGNL expressions, The vulnerability allows an attacker to construct malicious data to remotely execute arbitrary code.
### CVE_2021_31805_POC_EXP.py
#### POC
pocsuite -r CVE_2021_31805_POC_EXP.py -u url

![1649996853(1)](https://user-images.githubusercontent.com/54984589/163518507-b5732b18-a9f7-473b-93a8-712d08e1f7a6.png)

#### EXP
pocsuite -r CVE_2021_31805_POC_EXP.py -u url --attack --command "[command]"

![1650007730(1)](https://user-images.githubusercontent.com/54984589/163539455-ce3e948e-44f0-4879-946e-64687b49368f.png)


# 免责声明
## 此工具仅用于学习、研究和自查。不应将其用于非法目的。使用本工具产生的一切风险与我无关!
# Disclaimer
## This tool is for study, research, and self-examination only. It should not be used for illegal purposes. All risks arising from the use of this tool have nothing to do with me!