On Wed, 2011-05-18 at 12:33 +0200, Michael Wood wrote: > > Then it seems the -F option should be removed from regpatch. Or > should regpatch be replaced with something similar to the Python script > you included below?
The latter would be preferable, but you'd have to be able to specify mountpoints for the hives. > >>---< > > sys.path.append(samba_python_path) > > from samba import registry > > import samba.getopt as options > > > > # Open the hive > > lp = sambaopts.get_loadparm() > > creds = credopts.get_credentials(lp) > > hive = registry.open_hive(hivepath, lp_ctx=lp, credentials=creds) > > So "hivepath" here is the path to e.g. some user's "NTUSER.DAT"? Indeed. > > # Mount the hive to HKEY_CURRENT_USER > > reg = registry.Registry() > > reg.mount_hive(hive, registry.HKEY_CURRENT_USER) > > reg.diff_apply(patchfile) > >>---< Regards, Wilco Baan Hofman -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/options/samba
