summaryrefslogtreecommitdiff
path: root/usr.bin/ssh
diff options
context:
space:
mode:
authorRicardo Mestre <mestre@cvs.openbsd.org>2017-06-23 07:24:49 +0000
committerRicardo Mestre <mestre@cvs.openbsd.org>2017-06-23 07:24:49 +0000
commitfe69b4b73b00ffce54362518f740bf9540854a80 (patch)
tree370bfd1cc1f2f5401116800d2f8b3bb3074ac5d3 /usr.bin/ssh
parentea643b55a01e874ab334df7e024e632a2673dc26 (diff)
When using the escape sequence &~ the code path is client_loop() ->
client_simple_escape_filter() -> process_escapes() -> fork() and the pledge for this path lacks the proc promise and therefore aborts the process. The solution is to just add proc the promise to this specific pledge. Reported by Gregoire Jadi gjadi ! omecha.info Insight with tb@, OK jca@
Diffstat (limited to 'usr.bin/ssh')
-rw-r--r--usr.bin/ssh/clientloop.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/ssh/clientloop.c b/usr.bin/ssh/clientloop.c
index b1ed83f27d9..a762773d3a5 100644
--- a/usr.bin/ssh/clientloop.c
+++ b/usr.bin/ssh/clientloop.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: clientloop.c,v 1.299 2017/05/31 09:15:42 deraadt Exp $ */
+/* $OpenBSD: clientloop.c,v 1.300 2017/06/23 07:24:48 mestre Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -1246,7 +1246,7 @@ client_loop(int have_pty, int escape_char_arg, int ssh2_chan_id)
} else {
debug("pledge: network");
- if (pledge("stdio unix inet dns tty", NULL) == -1)
+ if (pledge("stdio unix inet dns proc tty", NULL) == -1)
fatal("%s pledge(): %s", __func__, strerror(errno));
}