LX0-104 · Question #22
In case neither cron.allow nor cron.deny exist in /etc/, which of the following is true?
The correct answer is A. Without additional configuration, no users may have user specific crontabs.. If neither /etc/cron.allow nor /etc/cron.deny files exist, cron typically defaults to allowing only the root user to create crontabs, preventing other users from doing so.
Question
Options
- AWithout additional configuration, no users may have user specific crontabs.
- BWithout additional configuration, all users may have user specific crontabs.
- CThe cron daemon will refuse to start and report missing files in the system's logfile.
- DWhen a user creates a user specific crontab the system administrator must approve it explicitly.
How the community answered
(25 responses)- A88% (22)
- C4% (1)
- D8% (2)
Why each option
If neither `/etc/cron.allow` nor `/etc/cron.deny` files exist, `cron` typically defaults to allowing only the root user to create crontabs, preventing other users from doing so.
When neither `cron.allow` nor `cron.deny` files are present in `/etc/`, the `cron` daemon's default behavior, as specified in many Linux implementations (like Vixie cron), is to restrict user access to `crontab` functionality. In this scenario, only the root user is typically permitted to create or modify crontabs, enhancing security by default.
This is incorrect; the default behavior without these files is generally restrictive, not permissive, for non-root users.
The cron daemon will start normally even if these files are missing; it simply reverts to a default policy.
`cron` access is controlled by the presence or absence of these files, not by explicit administrator approval for each crontab creation.
Concept tested: cron access control defaults
Source: https://man7.org/linux/man-pages/man5/crontab.5.html
Topics
Community Discussion
No community discussion yet for this question.