wasnt nate

Registry Hacking

Add Everyone Group to a Directory and Registry Key

For my next trick I’ll add the Everyone group to first a directory and then a registry key.. First the everyone group needs to be found in a localizable friendly way var everyone = new SecurityIdentifier(WellKnownSidType.WorldSid, null); // Print the name for debugging var group = (NTAccount)everyone.Translate(typeof(NTAccount)); Console.WriteLine(“Found group: {0}”, group); Now that the value is known, let’s grant it full access to a folder var [...]

Howto: Update Permissions on Registry Key

I needed to update a Registry Key programmatically to allow everyone full control. It also needed to work in various OS’s. The gotcha of this one ended up being an UnauthorizedException being thrown even though I was running fully elevated. It turned out that when opening a key by default it is read-only, unless you [...]

Monitoring a Registry Key for Changes

In the middle of this 8 hour automation run, we had some random process that was corrupting a few Registry values. To hunt down where this was occuring, I startd with Process Monitor. This worked great until the machine rebooted. Fair enough, turn on boot logging problem solved. Unfortunately the machine would reboot multiple times throughout the automation. [...]

Configuring a Microsoft Keyboard Favorites via Registry

The Control panel application for configuring the favorites of my “Microsoft Natural Ergonomic Keyboard 4000″ has become unusable. To hack around this open up regedit and find key HKCU\Software\Microsoft\IntelliType Pro\Model Specific\{ModelNumber}\EventMapping\{KeyNum} where : {ModelNumber} needs to be replaced with the correct id. For mine it was 1016. where : {KeyNum} is numeric value 79 through [...]