Don't allow a slash to be specified in a module name.
[rsync/rsync.git] / loadparm.c
index 0915000..010e089 100644 (file)
@@ -784,6 +784,11 @@ static BOOL do_section(char *sectionname)
      return(True);
    }
 
      return(True);
    }
 
+   if (strchr(sectionname, '/') != NULL) {
+     rprintf(FLOG, "Warning: invalid section name in configuration file: %s\n", sectionname);
+     return False;
+   }
+
    /* if we have a current service, tidy it up before moving on */
    bRetval = True;
 
    /* if we have a current service, tidy it up before moving on */
    bRetval = True;