As we should not be filling it.
This means we don't mess up a stock install where the pkg admin
hasn't setup privsep correctly.
return -1;
}
+ /* If we pickup the _dhcp user refuse the default directory */
+ if (strcmp(pw->pw_dir, "/var/empty") == 0) {
+ logerrx("refusing chroot: %s: %s", PRIVSEP_USER, pw->pw_dir);
+ errno = 0;
+ return -1;
+ }
+
/* Create the database directory. */
if (snprintf(path, sizeof(path), "%s%s", pw->pw_dir, DBDIR) == -1 ||
ps_mkdir(path) == -1 ||