kemra102 / puppet-auditd

Manage the audit daemon and it's rules.
BSD 2-Clause "Simplified" License
14 stars 54 forks source link

Pass concat::fragment target to function rather than getting from auditd::params #32

Closed cetanu closed 6 years ago

cetanu commented 7 years ago

Hello!

We just came across an interesting bug in our environment.

We are running SLES 12 and we noticed first that rules weren't being picked up from /etc/auditd/rules.d/puppet.rules.

We changed the auditd::rules_file param to /etc/auditd/audit.rules and then encountered a bunch of warnings that said that /etc/auditd/rules.d/puppet.rules doesn't exist in the catalog!

This striked us as odd, and we think that the function is not correctly getting the hiera value that we provided to the module.

Please see my pull request, as I believe this fixes the issue, while retaining previous expected behaviors.

As an interesting side effect, I think that this would also allow people to specify a different target for different rules in hiera. Although I can't imagine why anyone would.

kemra102 commented 6 years ago

Should be fixed by #43 - pleas re-open if required.