RHEL's fapolicyd
docs show how to whitelist a specific application, but is there a way to whitelist an entire directory structure of files consisting of php, js, css and pdf types?
Using fapolicyd
in debug mode:
# fapolicyd --debug-deny 2> fapolicy.output &
My denial output looks like:
rule=11 dec=deny_audit perm=open auid=1000 pid=3005001 exe=/usr/libexec/openssh/sftp-server : path=/data/www/nbsprod/public_html/fax.php ftype=text/x-php trust=0
This occurs when one of our developers attempts to upload an existing file to the www directory.
If I set fapolicyd
to permissive, the file is uploaded no problems.