summaryrefslogtreecommitdiffstats
path: root/usr.bin/ssh/ssh-agent.c
diff options
context:
space:
mode:
authordoug <doug@openbsd.org>2015-12-11 17:41:37 +0000
committerdoug <doug@openbsd.org>2015-12-11 17:41:37 +0000
commit0bca08f1a3d70cfdf1dd7e539038f3573e36bfa5 (patch)
tree617ca96e0b4c3823ac2dbfa93b1570f50c2b015c /usr.bin/ssh/ssh-agent.c
parentpledge spamlogd - again from Ricardo Mestre <serial@helheim.mooo.com> - Thanks! (diff)
downloadwireguard-openbsd-0bca08f1a3d70cfdf1dd7e539038f3573e36bfa5.tar.xz
wireguard-openbsd-0bca08f1a3d70cfdf1dd7e539038f3573e36bfa5.zip
Add "id" to ssh-agent pledge for subprocess support.
Found the hard way by Jan Johansson when using ssh-agent with X. Also, rearranged proc/exec and retval to match other pledge calls in the tree. ok djm@
Diffstat (limited to 'usr.bin/ssh/ssh-agent.c')
-rw-r--r--usr.bin/ssh/ssh-agent.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/ssh/ssh-agent.c b/usr.bin/ssh/ssh-agent.c
index 5adc6b09e14..771c4191f36 100644
--- a/usr.bin/ssh/ssh-agent.c
+++ b/usr.bin/ssh/ssh-agent.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ssh-agent.c,v 1.210 2015/12/11 02:29:03 dtucker Exp $ */
+/* $OpenBSD: ssh-agent.c,v 1.211 2015/12/11 17:41:37 doug Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -1384,7 +1384,7 @@ skip:
signal(SIGTERM, cleanup_handler);
nalloc = 0;
- if (pledge("stdio cpath unix exec proc", NULL) != 0)
+ if (pledge("stdio cpath unix id proc exec", NULL) == -1)
fatal("%s: pledge: %s", __progname, strerror(errno));
while (1) {