If you deleted that mysterious Windows file Microsoft told you not to, there’s a new script to restore it

If you find yourself in the unfortunate position of having deleted the enigmatic ‘inetpub’ folder, Microsoft has come to the rescue with a PowerShell script designed to facilitate its restoration. This folder, which began appearing on system drives (C:) following the April 2025 security update for Windows 10 and 11, is not just a benign presence; it plays a pivotal role in safeguarding users against a significant security vulnerability known as CVE-2025-21204.

The Importance of the inetpub Folder

Initially, the appearance of the inetpub folder left many users puzzled, as it contained no visible files. However, Microsoft has since clarified its importance. The folder is essential for securing systems against CVE-2025-21204, which pertains to “improper link resolution before file access” within the Windows Update Stack. This vulnerability poses a risk by potentially allowing an authorized attacker to escalate privileges if successfully exploited.

While users have the option to recreate the inetpub folder by enabling Internet Information Services (IIS) through the “Turn Windows features on or off” menu, this method may introduce additional system folders that some users might prefer to avoid. Therefore, utilizing Microsoft’s script-based solution is the recommended course of action for those who have inadvertently removed the folder.

It is crucial to note that even though the inetpub folder appears empty and IIS may not be actively in use, its deletion can undermine the effectiveness of the associated security patch. This could leave systems exposed to potential vulnerabilities. Microsoft strongly advises against removing the folder under any circumstances, emphasizing its role in maintaining system integrity and security.

Follow Tom’s Hardware on Google News to stay informed with the latest news, analysis, and reviews. Don’t forget to click the Follow button.

Winsage
If you deleted that mysterious Windows file Microsoft told you not to, there's a new script to restore it