From 2e738484c5722cf14e1414be66eeb5110bd2834c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Leonardo=20M=C3=B6rlein?= Date: Fri, 8 May 2020 02:58:24 +0200 Subject: [PATCH] jail: SIGSEGV must not be forwarded to the child process MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit 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 --- jail/jail.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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; -- 2.25.1