Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement: Add a new task for configuring fapolicyd rules #132

Open
merillr opened this issue Sep 9, 2022 · 2 comments
Open

Enhancement: Add a new task for configuring fapolicyd rules #132

merillr opened this issue Sep 9, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@merillr
Copy link

merillr commented Sep 9, 2022

Since the installation only supports tgz, systems running fapolicyd (such as DISA STIG-compliant RHEL8+ servers) block splunk from executing. Below is a snippet of the rules preventing execution after running fapolicyd --debug-deny:

rule=11 dec=deny_audit perm=open auid=-1 pid=29811 exe=/opt/splunk/bin/python3.7m : path=/opt/splunk/lib/python3.7/encodings/__pycache__/__init__.cpython-37.pyc ftype=application/x-bytecode.python trust=0
rule=8 dec=deny_audit perm=open auid=-1 pid=29812 exe=/opt/splunk/bin/python3.7m : path=/opt/splunk/lib/libdlwrapper.so.1.0.0 ftype=application/x-sharedlib trust=0
rule=13 dec=deny_audit perm=execute auid=-1 pid=29813 exe=/usr/bin/bash : path=/opt/splunk/bin/python3.7m ftype=application/x-executable trust=0

Some options are:

  1. Add a task to create the fapolicyd rules.d files and update the fapolicyd database.
  2. Add a task to create the fapolicd trusted.d files to whitelist specific directories (only works if directories don't change because of SHA-256 hashing).
  3. Support RPM-based installation (Enhancement: Install/upgrade from RPM/deb OS packages when compatible with target OS #7), since applications registered in the system RPM database are automatically trusted.

References:
https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/security_hardening/assembly_blocking-and-allowing-applications-using-fapolicyd_security-hardening
https://www.stigviewer.com/stig/red_hat_enterprise_linux_8/2020-11-25/finding/V-230523

@dtwersky dtwersky added the enhancement New feature or request label Oct 7, 2022
@dtwersky
Copy link
Collaborator

dtwersky commented Oct 7, 2022

@merillr I don't see an issue with this being implemented, and as you said, this can be done by adding an option to install the package or adding a custom rule.
I would rather have it install the package, and not have to create rules, because we will have to update the SHA for every executable it will be executing, and I'm not sure how many we will need to add to that rule, and if additional executables are added in the future, we will need to edit the playbook every time.

You are welcome to open a PR to add the RPM functionality, or wait till I have some time to work on this, since this will require quite a bit of work for it to be future proof and easily configurable.

@arcsector
Copy link
Contributor

arcsector commented Dec 21, 2022

Would this be something that would need to be done for both UFs and Full installs, or just Full? Last I heard from Splunk support, they don't have OOTB support for STIG-compliant systems, which is fairly disheartening from a company that works with the government a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants