add direct access registry methods

This adds registry access methods that do an atomic open/<action>/close on
registry keys. They improve efficiency and safety, since we're not passing
HKEY's back and forth to enumerate or read registry keys. This better fits the
common usage patterns anyway.

This is part of the fix for https://github.com/rapid7/metasploit-framework/issues/3693