summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2015-10-04 15:54:15 +0000
committerderaadt <deraadt@openbsd.org>2015-10-04 15:54:15 +0000
commit8b8ebde94e244fbcba09a19fa9ac2e5dfc201c9f (patch)
treea82037bb01526ffe6316e06137fc59fc60000414
parentRemove useless pattern_t typedef, POSIX regex is here to stay so (diff)
downloadwireguard-openbsd-8b8ebde94e244fbcba09a19fa9ac2e5dfc201c9f.tar.xz
wireguard-openbsd-8b8ebde94e244fbcba09a19fa9ac2e5dfc201c9f.zip
df is a tame "stdio rpath" program, the rpath due to getfsstat and statfs.
those two system calls were put into the "rpath" catagory because they expose pathname information.
-rw-r--r--bin/df/df.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/df/df.c b/bin/df/df.c
index d4d928c5471..07d549736e2 100644
--- a/bin/df/df.c
+++ b/bin/df/df.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: df.c,v 1.52 2015/01/16 06:39:31 deraadt Exp $ */
+/* $OpenBSD: df.c,v 1.53 2015/10/04 15:54:15 deraadt Exp $ */
/* $NetBSD: df.c,v 1.21.2.1 1995/11/01 00:06:11 jtc Exp $ */
/*
@@ -79,6 +79,9 @@ main(int argc, char *argv[])
int width, maxwidth;
char *mntpt;
+ if (tame("stdio rpath", NULL) == -1)
+ err(1, "tame");
+
while ((ch = getopt(argc, argv, "hiklnPt:")) != -1)
switch (ch) {
case 'h':