From: deraadt Date: Fri, 16 Oct 2015 22:54:15 +0000 (+0000) Subject: pledge "stdio rpath wpath cpath fattr proc exec" X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=c26df687f4871e042f5727781b17ca4dfefd2d60;p=openbsd pledge "stdio rpath wpath cpath fattr proc exec" --- diff --git a/usr.sbin/vipw/vipw.c b/usr.sbin/vipw/vipw.c index b6700a5a982..3838b9ab51d 100644 --- a/usr.sbin/vipw/vipw.c +++ b/usr.sbin/vipw/vipw.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vipw.c,v 1.17 2014/05/07 21:20:06 schwarze Exp $ */ +/* $OpenBSD: vipw.c,v 1.18 2015/10/16 22:54:15 deraadt Exp $ */ /* * Copyright (c) 1987, 1993, 1994 @@ -64,6 +64,9 @@ main(int argc, char *argv[]) if (argc != 0) usage(); + if (pledge("stdio rpath wpath cpath fattr proc exec", NULL) == -1) + err(1, "pledge"); + pw_init(); tfd = pw_lock(0); if (tfd < 0)