Take ownership of the Windows Apps folders

The biggest difference between Steam and MS Store versions of MSFS is the access to folders. Many have expressed concern that they cannot link outside add-ons to the Flight Simulator .exe file when required by that add-on.

In an attempt to ensure that software installed by the MS Store is secure and safe, MS implemented the WindowsApps Trusted Installer protocol. For users that insist on having administrative control over their computer this protocol can be overcome.

Couple of important points to begin with;

  • If you are not comfortable with adjusting low level settings you should enlist more expert assistance
  • Any changes listed below will require that you have administrative access on the system. These changes CAN NOT be completed otherwise
  • If the steps below are not followed carefully it is possible to mess up your system.

Your decision to attempt these changes is yours and yours alone. You have been warned! This is not NOVICE advice. You accept ALL responsibility for the outcome.

  • If the above messages scare you, stop here and do not attempt anything below this line.

There are two ways to take ownership of the Windows Apps folders. The method you chose has no bearing on the outcome. The method you chose simply depends on your preference and level of expertise and understanding.

Full Manual

In this method, you will go through and make manual changes to existing setting using the standard Windows UI.

  • Step one is to make sure you can find the folder. It is normally hidden from view and so you will need to “un hide” it. Click `VIEW’ on any folder view window. You will see a check box beside HIDDEN ITEMS. make sure it is checked.

  • Now navigate to the drive that your Windows is installed on.
  • Open the Program Files folder.
  • Scroll down to find the WindowsApps folder.
  • Right Click on the folder.
    ~ Select - Properties
    ~ On the WindowsApps Properties window click on the Security tab.
    image
    ~ At the bottom of the tab, click Advanced.
  • You should now see the Advanced Security Settings window.

    ~ click on the Change link.
  • You are now on the Select User or Group window.
    ~ type Administrator and click Check Names.
    ~ as long as you didn’t make a spelling error you should see the full name of the adminstrator account appear. Obviously it will be the name of your computer, not mine.:slight_smile:
  • Click OK to get back to the Advanced Security Settings window.
  • Confirm the new owner is the one you selected on the Select User or Group window.
    ~ Place a check mark in the box beside Replace owner on sub-containers and objects
    ~ * note: you may notice that full access is not granted in the permissions for your administrator. You can change this later if required but not now. We must complete the ownership change first.
  • Click APPLY
    You will get a message box pop up telling you the changes are being applied. Followed by another box when complete telling you that you must exit the properties UI before you can make an permission changes. (told you so) Just click OK on that one and Click OK on the remaining windows until the Properties window is closed.
    Now you can go back to the Advanced Security Settings and make any permission changes you would like. I do not suggest changing ANY permissions other than those for the administrator.
Automatic

This method makes changes to the registry and adds an option in the context menu to make changing ownership of folders far simpler. The only real downside to this is if you are not the only one using the computer you will give giving the power to change ownership to anyone that desires it.

The upside is it is much quicker and easier and there are a couple versions available that allow you to both take ownership and give it back with the click of a button.

You can download the .reg files here as well as review the tutorial for its use. There are a few different version available depending on your usage preferences so take a moment to review the page.

This context menu will only work with English Windows 10 installations.

The author has, however, kindly offered to make this available for non English installations on request through the above link.

You can review the changes that the “Take Ownership” .reg install will perform below


Registry Edit Summary

Windows Registry Editor Version 5.00

; Created by: Shawn Brink
; Created on: January 28th 2015
; Updated on: February 16th 2018

[HKEY_CLASSES_ROOT*\shell\TakeOwnership]
@=“Take Ownership”
“HasLUAShield”=“”
“NoWorkingDirectory”=“”
“Position”=“middle”

[HKEY_CLASSES_ROOT*\shell\TakeOwnership\command]
@=“powershell -windowstyle hidden -command "Start-Process cmd -ArgumentList ‘/c takeown /f \"%1\" && icacls \"%1\" /grant *S-1-3-4:F /t /c /l’ -Verb runAs"”
“IsolatedCommand”= “powershell -windowstyle hidden -command "Start-Process cmd -ArgumentList ‘/c takeown /f \"%1\" && icacls \"%1\" /grant *S-1-3-4:F /t /c /l’ -Verb runAs"”

[HKEY_CLASSES_ROOT\Directory\shell\TakeOwnership]
@=“Take Ownership”
“AppliesTo”=“NOT (System.ItemPathDisplay:="C:\Users" OR System.ItemPathDisplay:="C:\ProgramData" OR System.ItemPathDisplay:="C:\Windows" OR System.ItemPathDisplay:="C:\Windows\System32" OR System.ItemPathDisplay:="C:\Program Files" OR System.ItemPathDisplay:="C:\Program Files (x86)")”
“HasLUAShield”=“”
“NoWorkingDirectory”=“”
“Position”=“middle”

[HKEY_CLASSES_ROOT\Directory\shell\TakeOwnership\command]
@=“powershell -windowstyle hidden -command "Start-Process cmd -ArgumentList ‘/c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant *S-1-3-4:F /t /c /l /q’ -Verb runAs"”
“IsolatedCommand”=“powershell -windowstyle hidden -command "Start-Process cmd -ArgumentList ‘/c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant *S-1-3-4:F /t /c /l /q’ -Verb runAs"”

Some folks have reported that these steps don’t work. They do work. If they don’t work for you, then there is something else going on. You may have inadvertently skipped a step. You may have other security software running that prevents these changes from taking effect. You may not, in fact, have administrative access.

Bottom line. This works for the vast majority of users and has worked for more than 5 years of Windows changes. If you have issues then go back and review. Must have missed something. If your understanding of the process behind this is lacking then best to enlist that “more expert” help I mentioned at the beginning.

1 Like

Is there a way to undo the Full Manual method? If so, can you provide the steps?

Known workaround for MSFS folder permission/ownership issues - I have done the above many times since the release of MSFS.

Good instructions though, should be helpful to someone.

Thank you! Excellent info. Very useful/helpful. Greatly appreciated!

1 Like

For me i found out by accident to access the Windows app folder.
I tried to open it and access was denied due to lack of admin rights or permissions. I leave it at that.
Sometime later i was looking with the search function on the taskbar to the flightsimulator.exe and it open up the folder windowapps folder with all kinds of .dll files like coherentdraw.dll and much more including flightsimulator.exe,
Why i needed this file? i needed back then to modified it to change the settings of the stuttering issue with Su3.

It seems like the folder is protected to open, but the files in it are apparrently not.

Remember it is protected by a reason, it will fup your sim or worse.

Pretty sure it is restricted to avoid users easily accessing files they should not tamper with to ensure integrity and promote a fair online environment in FS2020. Easy to get around but only by those who know how. Doubt any real harm will come to the system if someone toyed with MSFS files
 there are far more damaging files left unrestrcted by Microsoft.

not working :frowning: FlightSimulator.exe is secured.
All files can be accessed but only the exe not. What a joke MS

Nuff said.

1 Like

Followed the steps exactly to this point and it doesn’t work - I can see that Administrator is now the owner but still get the same security prompts and cannot access.

Missed something then. 100% of the time it works. Be sure to follow any of the windows instructions carefully.

Looking more carefully - this only works if the “Administrator” account is local. If the admin user account is based on a MS account (like mine and others I suspect), then that has to be used for ownership.

To confirm the account name, run “echo %username%” in a command prompt.

2 Likes

Can confirm this. I changed to administrator and couldn’t access. Once changed ownership to my MS account everything is accessible now.

I don’t think it is as clear cut as some make out.

For example, on my work machine I performed the same operation. Took ownership of the entire folder, recursively, then went back in again, and granted my account full control.

Confirmed here by looking at a file further down in the tree. I’ve blurred out relevant entires for security reasons, but they are one and the same account.

image

When I try to rename this file it is denied, even after supplying my credentials. It won’t let me write into that folder either.

It’s possible my domain account is not working in much the same way as the non-local account above, but I have tested it with the local admin account and it also cannot rename files i.e. no write permissions.

I can however create a new folder inside “WindowsApps”, and rename folders in that folder, but nothing further down.

Re-tested using the built-in Administrator account, setting it as owner, and granting Full Control. This user also cannot alter certain files.

1 Like