Fapolicyd



Fapolicyd System Role

Requirements

This role is only supported on RHEL8.1+/CentOS8.1+ and Fedora distributions. Consider reading fapolicyd documentation before setting it up.

Role Variables

fapolicyd_setup_enable_service

Default true - if set to false the variable makes the service stopped and disabled.

fapolicyd_setup_trust

Default rpmdb,file - there can be list of sources for trust option file, rpmdb or deb(if compiled with debian support). The option specifies which sources of trust a loaded and in which order.

fapolicyd_setup_integrity

Default none - there are four supported types of integrity. No integrity none, defined by size of the file, defined by hash of the file sha256 and defined by hashes of files but generated from ima kernel subsystem. Note that IMA needs to be set up separately and this system role does not cover it.

fapolicyd_setup_permissive

Default false - if set to true deploys the daemon in permissive mode.

fapolicyd_setup_watch_fs

Default [ext2,ext3,ext4,tmpfs,xfs,vfat,iso9660,btrfs] - list of fs types watched. Any change here becomes the entire list of items, and the data in each should match the first column of /proc/mounts.

fapolicyd_add_trusted_paths

Default empty - list of files and directories that will be marked as trusted. Note that you cannot specify an empty directory.

fapolicyd_add_trusted_file

Deprecated alias for fapolicyd_add_trusted_paths. If fapolicyd_add_trusted_paths is not set, the role uses fapolicyd_add_trusted_file instead. Prefer fapolicyd_add_trusted_paths in new playbooks.

fapolicyd_rules_files

Default empty - list of rules files to manage in /etc/fapolicyd/rules.d. Each item has name (the role adds .rules), content, and state (present or absent, default present). Files not listed are left alone. On fapolicyd 1.5 or later, the role checks all rules with fapolicyd-cli --check-rules before writing any file, and fails without changing anything if the check fails. Older versions do not check rule syntax. Requires EL 8.6 or later.

fapolicyd_rules_files:
  - name: 99-deny-all
    content: |
      deny perm=any all : all
  - name: 80-old-rule
    state: absent

Example Playbook

---
- name: Example fapolicyd role invocation
  hosts: all
  vars:
    fapolicyd_setup_enable_service: true
    fapolicyd_setup_integrity: sha256
    fapolicyd_setup_trust: rpmdb,file
    fapolicyd_add_trusted_paths:
      - /etc/passwd
      - /etc/fapolicyd/fapolicyd.conf
      - /etc/krb5.conf
      - /opt/myapplication/bin  # a directory - must not be empty
  roles:
    - fapolicyd

rpm-ostree

See README-ostree.md

License

MIT

Author Information

Radovan Sroka @rsroka

Marko Myllynen @myllynen

citest.yml