CVE-2025-49704 Microsoft SharePoint Code Injection

Exploited in the wild High 8.8 Published Updated

An authorized attacker can execute arbitrary code remotely on Microsoft SharePoint Server via a code injection vulnerability.

Exploited in the wild
Since 22 Jul 2025
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2025-49704?

CVE-2025-49704 is a high-severity code injection vulnerability in Microsoft Sharepoint Server, published on 8 Jul 2025. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

Improper control of generation of code ('code injection') in Microsoft Office SharePoint allows an authorized attacker to execute code over a network.

Weakness: CWE-94

Which versions are affected by CVE-2025-49704?

It affects 1 product.

Products include Microsoft Sharepoint Server.

How do I fix CVE-2025-49704?

No fix has been published for CVE-2025-49704 yet. Limit exposure of the affected software until one is available. US federal agencies must fix it by 23 Jul 2025.

Upgrade, and never evaluate templates, expressions or code built from user input. More about Code injection.

Is CVE-2025-49704 being exploited?

Yes. Attackers have exploited CVE-2025-49704 in the wild since at least 22 Jul 2025, including in ransomware campaigns.

Public exploit code: 1 Metasploit module.

All Microsoft Sharepoint Server vulnerabilities

Sources

Also known as GHSA-mh5q-j7vq-g5g7.

Is CVE-2025-49704 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free