From: gilles Date: Tue, 13 Oct 2015 10:59:04 +0000 (+0000) Subject: pledge() control process X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=b0d27b30311efe32475c5343bc66872a01d8b3c1;p=openbsd pledge() control process ok deraadt@ --- diff --git a/usr.sbin/smtpd/control.c b/usr.sbin/smtpd/control.c index 68c2b992798..362a8f9787d 100644 --- a/usr.sbin/smtpd/control.c +++ b/usr.sbin/smtpd/control.c @@ -1,4 +1,4 @@ -/* $OpenBSD: control.c,v 1.105 2015/10/02 00:26:45 gilles Exp $ */ +/* $OpenBSD: control.c,v 1.106 2015/10/13 10:59:04 gilles Exp $ */ /* * Copyright (c) 2012 Gilles Chehade @@ -296,6 +296,9 @@ control(void) control_listen(); + if (pledge("stdio unix recvfd sendfd", NULL) == -1) + err(1, "pledge"); + if (event_dispatch() < 0) fatal("event_dispatch"); control_shutdown();