From 84c30cead1a68ce5b99a2578557ed0fb7809edca Mon Sep 17 00:00:00 2001 From: Brian Dwyer Date: Wed, 28 Nov 2018 16:48:28 -0500 Subject: [PATCH] Remove incorrect logic -- Should always be `/etc/auditd.conf` Signed-off-by: Brian Dwyer --- libraries/auditd_helper.rb | 9 --------- resources/conf_file.rb | 4 +--- 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/libraries/auditd_helper.rb b/libraries/auditd_helper.rb index 59a6a0f..ffc3ac9 100644 --- a/libraries/auditd_helper.rb +++ b/libraries/auditd_helper.rb @@ -33,14 +33,5 @@ def auditd_rulefile(ruleset = 'audit.rules') '/etc/audit/audit.rules' end end - - def auditd_conffile(conf_file = 'audit.conf') - if platform_family?('rhel') && node['platform_version'].to_i >= 6 - ::File.join('/etc/audit/', conf_file) - else - '/etc/audit/auditd.conf' - end - end - end end diff --git a/resources/conf_file.rb b/resources/conf_file.rb index c1ac764..4c82b78 100644 --- a/resources/conf_file.rb +++ b/resources/conf_file.rb @@ -20,9 +20,7 @@ property :cookbook, String action :create do - extend AuditD::Helper - - template auditd_conffile(new_resource.name) do + template '/etc/audit/auditd.conf' do source "#{new_resource.name}.conf.erb" cookbook new_resource.cookbook if new_resource.cookbook notifies :reload, 'service[auditd]'