In linux run the server in it's own container with separate IPC and PID namespace

This commit is contained in:
Nikos Mavrogiannopoulos
2015-01-14 17:08:01 +01:00
parent 1740a3aaf0
commit 4dee583e29
5 changed files with 45 additions and 1 deletions
+2 -1
View File
@@ -1122,7 +1122,7 @@ int main(int argc, char** argv)
break;
}
pid = fork();
pid = safe_fork();
if (pid == 0) { /* child */
/* close any open descriptors, and erase
* sensitive data before running the worker
@@ -1168,6 +1168,7 @@ int main(int argc, char** argv)
exit(0);
} else if (pid == -1) {
fork_failed:
mslog(s, NULL, LOG_ERR, "fork failed");
close(cmd_fd[0]);
} else { /* parent */
/* add_proc */