CVE-2025-26646 .NET, Visual Studio, and Build Tools for Visual Studio Spoofing Vulnerability

High 8.0 Published Updated

An authorized attacker can exploit external control of file names or paths in .NET and Visual Studio to perform spoofing over a network.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2025-26646?

CVE-2025-26646 is a high-severity path traversal vulnerability in Microsoft .Net, published on 13 May 2025. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.

Official description

External control of file name or path in .NET, Visual Studio, and Build Tools for Visual Studio allows an authorized attacker to perform spoofing over a network.

Weakness: CWE-73

Which versions are affected by CVE-2025-26646?

16 open source packages ship an affected version, including Microsoft.Build.Tasks.Core, dotnet and dotnet-sdk. It affects 3 products.

PackageAffectedFixed in
Microsoft.Build.Tasks.Core NuGetFrom 15.8.16615.9.30
Microsoft.Build.Tasks.Core NuGetFrom 15.8.16615.9.30
Microsoft.Build.Tasks.Core NuGetFrom 16.0.46116.11.6
Microsoft.Build.Tasks.Core NuGetFrom 16.0.46116.11.6
Microsoft.Build.Tasks.Core NuGetFrom 17.0.017.8.29
Microsoft.Build.Tasks.Core NuGetFrom 17.0.017.8.29
10 more packages
Microsoft.Build.Tasks.Core NuGetFrom 17.11.417.12.36
Microsoft.Build.Tasks.Core NuGetFrom 17.11.417.12.36
Microsoft.Build.Tasks.Core NuGetFrom 17.12.617.13.26
Microsoft.Build.Tasks.Core NuGetFrom 17.12.617.13.26
Microsoft.Build.Tasks.Core NuGetFrom 17.13.917.14.8
Microsoft.Build.Tasks.Core NuGetFrom 17.13.917.14.8
Microsoft.Build.Tasks.Core NuGetFrom 17.9.517.10.29
Microsoft.Build.Tasks.Core NuGetFrom 17.9.517.10.29
dotnet BitnamiFrom 8.0.08.0.16, 9.0.5
dotnet-sdk BitnamiFrom 8.0.08.0.101, 9.0.100
Linux distribution packages (24)
aspnetcore-runtime-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
aspnetcore-runtime-9.0 AlmaLinux:10All versions9.0.5-1.el10_0
aspnetcore-runtime-dbg-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
aspnetcore-runtime-dbg-9.0 AlmaLinux:10All versions9.0.5-1.el10_0
aspnetcore-targeting-pack-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
aspnetcore-targeting-pack-9.0 AlmaLinux:10All versions9.0.5-1.el10_0
dotnet-apphost-pack-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
dotnet-apphost-pack-9.0 AlmaLinux:10All versions9.0.5-1.el10_0
dotnet-host AlmaLinux:10All versions9.0.5-1.el10_0
dotnet-hostfxr-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
dotnet-hostfxr-9.0 AlmaLinux:10All versions9.0.5-1.el10_0
dotnet-runtime-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
dotnet-runtime-9.0 AlmaLinux:10All versions9.0.5-1.el10_0
dotnet-runtime-dbg-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
dotnet-runtime-dbg-9.0 AlmaLinux:10All versions9.0.5-1.el10_0
dotnet-sdk-8.0 AlmaLinux:10All versions8.0.116-1.el10_0
dotnet-sdk-8.0-source-built-artifacts AlmaLinux:10All versions8.0.116-1.el10_0
dotnet-sdk-9.0 AlmaLinux:10All versions9.0.106-1.el10_0
dotnet-sdk-9.0-source-built-artifacts AlmaLinux:10All versions9.0.106-1.el10_0
dotnet-sdk-aot-9.0 AlmaLinux:10All versions9.0.106-1.el10_0
dotnet-sdk-dbg-8.0 AlmaLinux:10All versions8.0.116-1.el10_0
dotnet-sdk-dbg-9.0 AlmaLinux:10All versions9.0.106-1.el10_0
dotnet-targeting-pack-8.0 AlmaLinux:10All versions8.0.16-1.el10_0
dotnet-targeting-pack-9.0 AlmaLinux:10All versions9.0.5-1.el10_0

Products include Microsoft .Net, Microsoft Build Tools, Microsoft Visual Studio 2022.

How do I fix CVE-2025-26646?

Upgrade Microsoft.Build.Tasks.Core to a fixed version for your release line: 15.9.30, 16.11.6, 17.8.29 or 17.12.36.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2025-26646 being exploited?

There is no known exploitation of CVE-2025-26646 in the wild and no public exploit code.

All Microsoft .Net vulnerabilities

Sources

Also known as ALSA-2025:7571, ALSA-2025:7589, ALSA-2025:7598, ALSA-2025:7599, ALSA-2025:7600, ALSA-2025:7601 and 23 more.

Is CVE-2025-26646 in your software?

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

Check your SBOMs for free