summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeonardo Mörlein2020-05-08 00:58:24 +0000
committerDaniel Golle2020-05-15 18:10:43 +0000
commit2e738484c5722cf14e1414be66eeb5110bd2834c (patch)
treef3ba309226a4e7476a017208c40bf830d21aadb3
parent17e7ae769a4739e4b41a93f588d52cfd216b8eb2 (diff)
downloadprocd-2e738484c5722cf14e1414be66eeb5110bd2834c.tar.gz
jail: SIGSEGV must not be forwarded to the child process
A segfault in ujail caused ujail to hang with no chance to abort. Raising the debug level revealed that SIGSEGV was delivered to the child process instead of handled directly by ujail. The corresponding debug message was triggered infinitely again and again: forwarding signal 11 to the jailed process forwarding signal 11 to the jailed process forwarding signal 11 to the jailed process forwarding signal 11 to the jailed process forwarding signal 11 to the jailed process forwarding signal 11 to the jailed process forwarding signal 11 to the jailed process [...] Signed-off-by: Leonardo Mörlein <me@irrelefant.net>
-rw-r--r--jail/jail.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/jail/jail.c b/jail/jail.c
index 8ae477c..67d4cad 100644
--- a/jail/jail.c
+++ b/jail/jail.c
@@ -775,7 +775,7 @@ int main(int argc, char **argv)
if (!sigismember(&sigmask, i))
continue;
- if ((i == SIGCHLD) || (i == SIGPIPE))
+ if ((i == SIGCHLD) || (i == SIGPIPE) || (i == SIGSEGV))
continue;
s.sa_handler = jail_handle_signal;