capsicum_helpers: Add LOOKUP flag
authorcem <cem@FreeBSD.org>
Fri, 16 Dec 2016 01:37:44 +0000 (01:37 +0000)
committercem <cem@FreeBSD.org>
Fri, 16 Dec 2016 01:37:44 +0000 (01:37 +0000)
commitada5397372dd5a0da1cc01e258304bc884bb052e
tree61c25f615feeabe21f263aa4bf1e29a3c98869b7
parenta2dc5b52c4fe7d645c59ca9269637bc441cfb430
capsicum_helpers: Add LOOKUP flag

Add a helper routine for opening a directory that is restricted to being
used for opening relative files as stdio streams.

I think this will really help basic adaptation of multi-file programs to
Capsicum. Rather than having each program initialize a rights object and
ioctl/fcntl arrays for their root fd for relative opens, consolidate in the
logical place.

Reviewed by: oshogbo@
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D8743
lib/libcapsicum/capsicum_helpers.h