SharePoint “ToolShell” (CVE-2025-53770): on-premises SharePoint servers under attack

A zero-day in on-premises SharePoint let attackers run code and steal server keys. Why patching had to be followed by rotating machine keys.

Publicly disclosed: 19 July 2025

On 19 July 2025 Microsoft published guidance about active attacks on on-premises SharePoint servers. The vulnerability, nicknamed “ToolShell”, allowed unauthenticated remote code execution; it bypassed a fix released earlier that month. Attackers planted web shells and stole the ASP.NET machine keys, which let them keep access even after patching.

CVESeverityAffectedFixed in
CVE-2025-53770Critical, CVSS 9.8 (deserialization, remote code execution)SharePoint Server 2016, 2019 and Subscription Edition (on-premises)Emergency security updates from July 2025

SharePoint Online in Microsoft 365 was not affected.

How to protect

  1. Install the latest security updates for all on-premises SharePoint servers; plan to leave versions that are out of support.
  2. Rotate the ASP.NET machine keys after updating and restart IIS — stolen keys otherwise remain usable.
  3. Enable AMSI integration and endpoint protection on SharePoint servers.
  4. Look for signs of compromise, such as unexpected .aspx files in the SharePoint layouts folders, and investigate if found.
  5. Do not publish internal SharePoint to the internet without strong protection (VPN, reverse proxy with pre-authentication).

After a key-stealing attack, a patch locks the door — but you still have to change the keys.

Sources: Microsoft MSRC guidance, NVD CVE-2025-53770.

Need help with this? Contact CySec for a free consultation.


All articles

Need help with this?

Our engineers can review your current setup and propose concrete improvements.