Using the old RegOpenKey (from Win 3.1), guess what it’s access mask is

Little tidbit. If you happen to be using the old RegOpenKey (from Win 3.1), guess what it’s access mask is?

If you look in MSDN, they will say that the key is opened with the ‘default security mask’. Well, I took a look at the code, and that mask is 0x2000000. After digging into MS’s wrapper code, you will find that the code is equal to MAXIMUM_ALLOWED.

This entry was posted in General. Bookmark the permalink.