If you’ve taken ownership of a protected file, folder, or registry key, you should change it back to the default TrustedInstaller owner after making changes.
TrustedInstaller is a built-in user account in all versions of Windows that owns various system files, including some files in the Windows and Program Files folders. TrustedInstaller is also the owner of the Windows.old folder, which is created when you update to a newer version of Windows and allows you to roll back to the previous version.
The TrustedInstaller user account is used by the Windows Modules Installer service, so TrustedInstaller has exclusive permission to install, modify, and remove Windows updates and other optional Windows components.
Access the Advanced Security Settings for a File or Folder
If you’re restoring TrustedInstaller as the owner of a file or folder, right-click on the file or folder and select Properties.
Access the Advanced Security Settings for a Registry Key
If you’re restoring TrustedInstaller as the owner of a registry key, first open the Registry Editor.
Press Windows key + R to open the Run dialog box. Then, type: regedit and hit Enter or click OK.
If the User Account Control dialog box displays, click Yes to continue. You may not see this dialog box, depending on your User Account Control settings.
Navigate to the registry key you want to restore ownership back to TrustedInstaller for. You can enter the path to the key in the box just under the menu bar, and press Enter to get to the key quickly.
Right-click on the key and select Permissions.
Restore TrustedInstaller as the Owner of a File, Folder, or Registry Key
If you’re changing the owner of a file or folder, the Properties dialog box displays. If you’re changing the owner of a registry key, the Permissions dialog box displays. But they’re both similar.
On the Security tab or either dialog box, click Advanced.
On the Advanced Security Settings dialog box, click the Change link to the right of Owner.
In the Enter the object name to select box on the Select User or Group dialog box, type: NT SERVICE\TrustedInstaller and then click Check Names.
NT SERVICE\TrustedInstaller changes to the official TrustedInstaller username.
Click OK to accept the change and close the Select User or Group dialog box.
The Owner changes to TrustedInstaller on the Advanced Security Settings dialog box.
If you’re changing the owner back to TrustedInstaller for a folder that has subfolders or a protected registry key that has subkeys, you can make sure the owner changes to TrustedInstaller for all the subfolders or subkeys.
To do this, check the “Replace owner on subcontainers and objects” box on the Advanced Security Settings dialog box.
Then, click OK.
Click OK on the Properties or Permissions dialog box.
Be Very Careful When Modifying System Files or Protected Registry Keys
The TrustedInstaller user account owns your system files and folders and protected registry keys for a reason. If you rename or edit any of these items, Windows will stop functioning, and you’ll likely have to repair it or even reinstall it.
You should only take ownership of system files and folders and protected registry keys and rename, delete, or move them if you know what you’re doing. Also, be sure to change the owner back to TrustedInstaller after making your changes.