Load registry user hive

by Apr 27, 2011

If you need to manipulate registry data from another user, you may be out of luck because HKEY_CURRENT_USER always points to your own user data. However, you can  manually load a user hive like this:

reg.exe /load HKU\Testuser c:\users\tom\ntuser.dat
PS > dir Registry::HKEY_USERS\Testuser\Software

 

This will load Tom’s registry settings into HKEY_USERS\Testuser and once loaded, PowerShell can then access and even manipulate that data.

 

Twitter This Tip!
ReTweet this Tip!