Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chef/Modernize/CronDFileOrTemplate matches on /etc/cron.deny #946

Open
tas50 opened this issue Feb 8, 2022 · 3 comments
Open

Chef/Modernize/CronDFileOrTemplate matches on /etc/cron.deny #946

tas50 opened this issue Feb 8, 2022 · 3 comments
Labels
Status: Untriaged An issue that has yet to be triaged. Type: Bug Does not work as expected.

Comments

@tas50
Copy link
Contributor

tas50 commented Feb 8, 2022

/etc/cron.deny is matching with the Chef/Modernize/CronDFileOrTemplate cop. Example:

file '/etc/cron.deny' do
  action :delete
end
@tas50 tas50 added Type: Bug Does not work as expected. Status: Untriaged An issue that has yet to be triaged. labels Feb 8, 2022
@draksha22
Copy link

hey @tas50 can you please elaborate your issue.

@ddamw
Copy link

ddamw commented Mar 9, 2022

cron.deny and cron.allow are special files that can be placed in /etc/cron.d that allow or deny access to crontab. Their contents are completely different from regular cron.d files and as such can not be serviced by the cron_d resource.

Source: https://docs.oracle.com/cd/E19253-01/817-0403/sysrescron-23/index.html

I noticed that @tas50 is not even processing the file in /etc/cron.d, but in /etc instead, which should not trigger the warning at all imho. I noticed something similar with cron.daily, but will report that in a new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Untriaged An issue that has yet to be triaged. Type: Bug Does not work as expected.
Projects
None yet
Development

No branches or pull requests

4 participants
@tas50 @ddamw @draksha22 and others