CFINSPEC-78: Add rules property for the resource

Signed-off-by: Sonu Saha <sonu.saha@progress.com>
This commit is contained in:
Sonu Saha 2022-04-14 11:20:15 +05:30
parent be4e6f7594
commit 2e243617a5

View file

@ -51,7 +51,11 @@ module Inspec::Resources
end
def rules
"some_value"
auditctl_cmd = inspec.command("#{auditctl_utility} -l")
raise Inspec::Exceptions::ResourceFailed, "Executing #{auditctl_utility} -l: #{auditctl_cmd.stderr}" if auditctl_cmd.exit_status.to_i != 0
auditctl_cmd.stdout.strip.split("\n")
end
private