summaryrefslogtreecommitdiffstats
path: root/usr.sbin/iscsictl
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2015-11-11 02:55:12 +0000
committerderaadt <deraadt@openbsd.org>2015-11-11 02:55:12 +0000
commited720fabf584a3bb3ec1475ad73488f4dac226d3 (patch)
treefb44b7b848bf9e2538665ef93968b0e40278a31c /usr.sbin/iscsictl
parentexit() after perror() for pledge failure. Perhaps this got introduced (diff)
downloadwireguard-openbsd-ed720fabf584a3bb3ec1475ad73488f4dac226d3.tar.xz
wireguard-openbsd-ed720fabf584a3bb3ec1475ad73488f4dac226d3.zip
claudio twice told me pledge "stdio rpath dns" is probably enough.
He'll test it next time he builds...
Diffstat (limited to 'usr.sbin/iscsictl')
-rw-r--r--usr.sbin/iscsictl/iscsictl.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/usr.sbin/iscsictl/iscsictl.c b/usr.sbin/iscsictl/iscsictl.c
index cb981131fad..6c3460101e0 100644
--- a/usr.sbin/iscsictl/iscsictl.c
+++ b/usr.sbin/iscsictl/iscsictl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: iscsictl.c,v 1.9 2015/01/16 06:40:17 deraadt Exp $ */
+/* $OpenBSD: iscsictl.c,v 1.10 2015/11/11 02:55:12 deraadt Exp $ */
/*
* Copyright (c) 2010 Claudio Jeker <claudio@openbsd.org>
@@ -104,6 +104,9 @@ main (int argc, char* argv[])
if (connect(control.fd, (struct sockaddr *)&sun, sizeof(sun)) == -1)
err(1, "connect: %s", sockname);
+ if (pledge("stdio rpath dns", NULL) == -1)
+ err(1, "pledge");
+
switch (res->action) {
case NONE:
case LOG_VERBOSE: