Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 9 Aug 2017 18:15:07 +0000 (UTC)
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r322324 - head/lib/libcapsicum
Message-ID:  <201708091815.v79IF7Nx032137@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kevans
Date: Wed Aug  9 18:15:07 2017
New Revision: 322324
URL: https://svnweb.freebsd.org/changeset/base/322324

Log:
  capsicum_helpers: Add FIODTYPE to default ioctls allowed
  
  FIODTYPE will be needed by hexdump(1) to speed up the -s flag on devices
  that should be able to support fseek(3); specifically, in an attempt to
  correct for the fact that most tape drives don't support seeking yet don't
  indicate as such when fseeko(3) is invoked. Related: D10939
  
  Reviewed by:	cem, emaste, oshogbo
  Approved by:	emaste (mentor)
  Differential Revision:	https://reviews.freebsd.org/D10937

Modified:
  head/lib/libcapsicum/capsicum_helpers.h

Modified: head/lib/libcapsicum/capsicum_helpers.h
==============================================================================
--- head/lib/libcapsicum/capsicum_helpers.h	Wed Aug  9 18:09:09 2017	(r322323)
+++ head/lib/libcapsicum/capsicum_helpers.h	Wed Aug  9 18:15:07 2017	(r322324)
@@ -31,6 +31,7 @@
 
 #include <sys/param.h>
 #include <sys/capsicum.h>
+#include <sys/ioctl.h>
 
 #include <errno.h>
 #include <nl_types.h>
@@ -47,7 +48,7 @@ static __inline int
 caph_limit_stream(int fd, int flags)
 {
 	cap_rights_t rights;
-	unsigned long cmds[] = { TIOCGETA, TIOCGWINSZ };
+	unsigned long cmds[] = { TIOCGETA, TIOCGWINSZ, FIODTYPE };
 
 	cap_rights_init(&rights, CAP_FCNTL, CAP_FSTAT, CAP_IOCTL);
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201708091815.v79IF7Nx032137>