• Nils Goroll's avatar
    add JAIL_MASTER_SYSTEM for system() calls from master · 900e9f39
    Nils Goroll authored
    Also (re)used to make fork privileges available when we start a
    subprocess: As we are going to apply the JAIL_SUBPROC privileges to the
    forked process, having slightly eleveated privileges only agross the
    fork() should not cause any harm.
    
    	-
    
    This concludes the current series of Solaris jail patches, hopefully.
    With this commit, varnishd started with pfexec ("root privileges") keeps
    the following privileges only (ppriv -v output) on Solaris:
    
    * master::
    
      flags = PRIV_AWARE
            E: file_read,file_write,net_access
            I: none
            P: file_read,file_write,net_access,net_privaddr,proc_exec,proc_fork,proc_info,proc_owner,proc_setid
            L: file_read,file_write,net_access,net_privaddr,proc_exec,proc_fork,proc_info,proc_owner,proc_setid
    
      notes:
    
      E: file_read is required for basic config files like /etc/netconfig
         net_access is required for CLI communication
    
         file_write could potentially be removed if any file write
         operations (e.g. writing vcl files) were wrapped with
         JAIL_MASTER_FILE, but I do not consider this a relevant gain for
         now.
    
         For other master jail states, E will be momentarily expanded.
    
      I: will be momentarily expanded for system()
    
      P: Contains the union of all privileges used anywhere in varnish
    
      L: Could potentially be reduced further, but P already limits
    
    * worker::
    
      flags = PRIV_AWARE
            E: file_read,file_write,net_access
            I: none
            P: file_read,file_write,net_access,proc_info
            L: file_read,file_write,net_access,proc_info,proc_setid
    
      proc_setid is only used when the worker starts and then dropped
    
      proc_info is only used by vmod_unix
    900e9f39
Name
Last commit
Last update
.circleci Loading commit data...
.github Loading commit data...
bin Loading commit data...
doc Loading commit data...
etc Loading commit data...
include Loading commit data...
lib Loading commit data...
m4 Loading commit data...
man Loading commit data...
tools Loading commit data...
.dir-locals.el Loading commit data...
.envrc Loading commit data...
.gitignore Loading commit data...
.lgtm.yml Loading commit data...
.syntastic_c_config Loading commit data...
.travis.yml Loading commit data...
CONTRIBUTING Loading commit data...
ChangeLog Loading commit data...
INSTALL Loading commit data...
LICENSE Loading commit data...
Makefile.am Loading commit data...
README.Packaging Loading commit data...
README.rst Loading commit data...
autogen.des Loading commit data...
autogen.sh Loading commit data...
configure.ac Loading commit data...
flint.lnt Loading commit data...
varnish-legacy.m4 Loading commit data...
varnish.m4 Loading commit data...
varnishapi-uninstalled.pc.in Loading commit data...
varnishapi.pc.in Loading commit data...
vtc.am Loading commit data...