python-registry: Read access to Windows Registry files
python-registry is a pure Python library that provides read-only access to Windows Registry files. These include NTUSER.DAT, userdiff, and SAM. The interface is two-fold: a high-level interface suitable for most tasks, and a low-level set of parsing objects and methods which may be used for the advanced study of the Windows Registry. The library is portable across all major platforms.
Download
git clone https://github.com/williballenthin/python-registry.git
Use
Most users will find the Registry.Registry module most appropriate. The module exposes three classes: the Registry, the RegistryKey, and the RegistryValue. The Registry organizes parsing and access to the Windows Registry file. The RegistryKey is a convenient interface into the tree-like structure of the Windows Registry. A RegistryKey may have children RegistryKeys, and may also have values associated with it. A RegistryValue can be thought of as the tuple (name, datatype, value) associated with a RegistryKey. python-registry supports all major data types, such as RegSZ, RegDWord, and RegBin.
To open a Windows Registry file, its this easy:
Print all keys in a Registry
Find a key and print all string values
Advanced users who wish to study the structure of the Windows Registry may find the Registry.RegistryParse module useful. This module implements all known structures of the Windows Registry.
Copyright (C) williballenthin