Description

A critical remote code execution (RCE) vulnerability has been uncovered in Microsoft SharePoint, allowing attackers to execute arbitrary code via malicious XML embedded within web parts. The issue stems from a flawed deserialization process linked to how SharePoint parses and reconstructs web part properties. At the core of the vulnerability is the AddParsedSubObject() method, which processes XML content from web parts. This content is deserialized through the ParseXml() method using XmlSerializer, ultimately leading to the execution of unsafe objects. The vulnerable chain continues with the GetAttachedProperties() method, where the SerializedAttachedPropertiesShared field is deserialized using SPObjectStateFormatter, a SharePoint-specific formatter that internally invokes the dangerous BinaryFormatter. The core of the exploit stems from SharePoint's SPSerializationBinder, which allows binary deserialization of any class listed as safe within the platform’s configuration.Attackers can abuse the SPThemes class—part of SafeControls and inheriting from DataSet—by embedding a serialized payload inside the AttachedPropertiesShared element of a malicious web part. When processed, this payload triggers arbitrary code execution. Exploitation is possible through the `/vti_bin/webpartpages.asmx` endpoint by invoking the `ConvertWebPartFormat` SOAP action. Attackers can remotely send crafted XML through unauthenticated HTTP POST requests, making this attack vector especially potent. The impact of a successful attack is severe. It grants full control over the compromised SharePoint server, enables access to sensitive information, and facilitates lateral movement across an organization’s internal network.