diff options
Diffstat (limited to 'source3/registry')
-rw-r--r-- | source3/registry/reg_smbconf.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/source3/registry/reg_smbconf.c b/source3/registry/reg_smbconf.c index b17422fdcb..3427645fa6 100644 --- a/source3/registry/reg_smbconf.c +++ b/source3/registry/reg_smbconf.c @@ -42,6 +42,19 @@ static int smbconf_fetch_values( const char *key, REGVAL_CTR *val ) static BOOL smbconf_store_values( const char *key, REGVAL_CTR *val ) { + int i; + int num_values = regval_ctr_numvals(val); + + for (i=0; i < num_values; i++) { + REGISTRY_VALUE *theval = regval_ctr_specific_value(val, i); + const char *valname = regval_name(theval); + + if (registry_smbconf_valname_forbidden(valname)) { + DEBUG(0, ("smbconf_store_values: value '%s' forbidden " + "in registry.\n", valname)); + return False; + } + } return regdb_ops.store_values(key, val); } |