*/
#include "includes.h"
+#include "registry.h"
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_REGISTRY
-extern REGISTRY_OPS regdb_ops; /* these are the default */
+extern struct registry_ops regdb_ops; /* these are the default */
-static int smbconf_fetch_keys( const char *key, REGSUBKEY_CTR *subkey_ctr )
+static int smbconf_fetch_keys( const char *key, struct regsubkey_ctr *subkey_ctr )
{
return regdb_ops.fetch_subkeys(key, subkey_ctr);
}
-static bool smbconf_store_keys( const char *key, REGSUBKEY_CTR *subkeys )
+static bool smbconf_store_keys( const char *key, struct regsubkey_ctr *subkeys )
{
return regdb_ops.store_subkeys(key, subkeys);
}
-static int smbconf_fetch_values( const char *key, REGVAL_CTR *val )
+static WERROR smbconf_create_subkey(const char *key, const char *subkey)
+{
+ return regdb_ops.create_subkey(key, subkey);
+}
+
+static WERROR smbconf_delete_subkey(const char *key, const char *subkey)
+{
+ return regdb_ops.delete_subkey(key, subkey);
+}
+
+static int smbconf_fetch_values(const char *key, struct regval_ctr *val)
{
return regdb_ops.fetch_values(key, val);
}
-static bool smbconf_store_values( const char *key, REGVAL_CTR *val )
+static bool smbconf_store_values(const char *key, struct regval_ctr *val)
{
return regdb_ops.store_values(key, val);
}
static bool smbconf_reg_access_check(const char *keyname, uint32 requested,
uint32 *granted,
- const struct nt_user_token *token)
+ const struct security_token *token)
{
if (!(user_has_privileges(token, &se_disk_operators))) {
return False;
* Table of function pointers for accessing smb.conf data
*/
-REGISTRY_OPS smbconf_reg_ops = {
+struct registry_ops smbconf_reg_ops = {
.fetch_subkeys = smbconf_fetch_keys,
.fetch_values = smbconf_fetch_values,
.store_subkeys = smbconf_store_keys,
.store_values = smbconf_store_values,
+ .create_subkey = smbconf_create_subkey,
+ .delete_subkey = smbconf_delete_subkey,
.reg_access_check = smbconf_reg_access_check,
.get_secdesc = smbconf_get_secdesc,
.set_secdesc = smbconf_set_secdesc,