ComplianceAsCode / content

Security automation content in SCAP, Bash, Ansible, and other formats
https://complianceascode.readthedocs.io/en/latest/
Other
2.22k stars 698 forks source link

How should the file_owner template handle symlinks? #12601

Open vojtapolasek opened 1 week ago

vojtapolasek commented 1 week ago

Description of problem:

The OVAL check of the file_owner template is not following symlinks. However, sometimes it might be a valid case. See https://github.com/ComplianceAsCode/content/pull/12590 for the context.

SCAP Security Guide Version:

33a7ba243d70917a657448fe32c0264bdaa33ca8

Operating System Version:

all

Steps to Reproduce:

  1. revert the https://github.com/ComplianceAsCode/content/pull/12590
  2. run test of rule file_owner_etc_issue on Fedora >= 40

Actual Results:

The test fails because there is a symlink /etc/issue by default on Fedora

Expected Results:

Tests should pass.