How to launch Windows Explorer with the privileges of a different domain user?

Solution 1:

You don't need to run explorer.exe as a different user just to connect to a network share with different credentials.

In an explorer window you can click on "Map network drive", fill in the path and and make sure to check "Connect using different credentials". When you click the finish button you will get prompted for the credentials you want to use to connect the current share.

You can also accomplish this with the net command on the command line.

net use x: \\server\share /user:[email protected] password

Solution 2:

It seems that Windows actively resists the ability to launch Explorer as a different user. I resolved this issue on my Windows 7 system by doing the following:

  1. take ownership of reg key HK_CLASSES_ROOT\AppID\{CDCBCFCA-3CDC-436f-A4E2-0E02075250C2}, and grant yourself Full Control. This key controls how Explorer is allowed to launch
  2. rename the subkey from runas to _runas. If you receive an error doing this, then you probably didn't complete step one correctly

Once this is changed, you can launch Explorer with a different set of credentials via the runas command or with the freeware tool CPAU from Joeware.

From command prompt, you can then launch Explorer:

  • with runas
    • runas /user:domain\username "c:\windows\explorer.exe /separate"
    • followed by completing the password prompt.
  • with cpau
    • cpau.exe /u domain\username /p password /ex "E:\Windows\explorer.exe /separate"

Note:

  • You have to use the Explorer option /separate to force Explorer to launch as a separate process. see also
  • The advantage of using cpau over runas is that with cpau, you can specify username and password in the command prompt.
  • Other than using cpau for my own use, I am not affiliated with Joeware.

Solution 3:

  • Go to the Start button;
  • Type in Explorer;
  • Shift Right-Click "Windows Explorer";
  • Run as different user.

That user will also need privileges to access the file system on the local machine, and perform any futher operations you'd like to execute.

Solution 4:

This works for Windows 7, 8.0, 8.1 and 10

  1. Start the Registry Editor as an Administrative User.
  2. Navigate to, take ownership of, and grant yourself Full Control permission to the key HKEY_CLASSES_ROOT\AppID\{CDCBCFCA-3CDC-436f-A4E2-0E02075250C2}
  3. Rename the value RunAs to _RunAs.
  4. Close Regedit.
  5. Create a shortcut on the Desktop to C:\Windows\Explorer.exe
  6. Right-click the shortcut and choose Run as administrator. This will open Explorer in the security context of the Administrator.