Bug 85879 - Allow root to use 'crontab -u userid' even if cron.allow prohibits it
Summary: Allow root to use 'crontab -u userid' even if cron.allow prohibits it
Alias: None
Product: Red Hat Raw Hide
Classification: Retired
Component: vixie-cron (Show other bugs)
(Show other bugs)
Version: 1.0
Hardware: All Linux
Target Milestone: ---
Assignee: Jens Petersen
QA Contact: Brock Organ
Keywords: FutureFeature
Depends On:
TreeView+ depends on / blocked
Reported: 2003-03-10 06:47 UTC by Valdis Kletnieks
Modified: 2007-04-18 16:51 UTC (History)
0 users

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-07-02 08:41:22 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
patch to cron misc.c to allow root to use -u flag (1.21 KB, patch)
2003-03-10 06:49 UTC, Valdis Kletnieks
no flags Details | Diff

Description Valdis Kletnieks 2003-03-10 06:47:21 UTC
Description of problem:
If a user isn't listed in cron.allow, but has a crontab entry *anyhow*, you
can't use crontab -u to work with that crontab.  

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Add user to cron.allow, add a crontab, then remove the user from cron.allow
2. crontab -l -u user
3. This fails to work even for root.
Actual results:
% su
# crontab -l -u testuser
You (testuser) are not allowed to use this program (crontab)
See crontab(1) for more information

Expected results:

Additional info:
A possible patch is appended.

Comment 1 Valdis Kletnieks 2003-03-10 06:49:26 UTC
Created attachment 90539 [details]
patch to cron misc.c to allow root to use -u flag

Here's a possible code fix for the enhancement.

Comment 2 Jens Petersen 2003-03-19 06:59:40 UTC
Looks good to me, thanks for the patch, Valdis.

Comment 3 Jens Petersen 2003-03-19 07:58:49 UTC
Patch should be in vixie-cron-3.0.1-75.  Thanks.

Note You need to log in before you can comment on or make changes to this bug.