1832587 Members
3227 Online
110043 Solutions
New Discussion

cron permissions

 
TMcB
Super Advisor

cron permissions

Hi everone

is it possible to set the permissions of the cron files so that only root can write to them.

We have been asked to set this up - so that the users can read their cron, and it will still run under their own accounts, but any changes to it will have to be done by the system administrators root account.

Thanks for any advice

7 REPLIES 7
BrianDoyle
Trusted Contributor

Re: cron permissions

Hi,
You can add users in cron.allow and cron.deny to assign access.

Have a look at this thread:

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1069663
TMcB
Super Advisor

Re: cron permissions

Hi
The users are in cron.allow - so their cron file exists.
But can I change the permissions so they cannot edit their own cron files ??

Cheers
Ivan Krastev
Honored Contributor

Re: cron permissions

You can remove WRITE permissions from files, but keep READ.

Note if the user is still owner of the file(s) he can change the permissions.

regards,
ivan
BrianDoyle
Trusted Contributor

Re: cron permissions

You must be the owner of the crontab file, then chmod the access to limit control to yourself
Yogeeraj_1
Honored Contributor

Re: cron permissions

hi,

this is quite difficult to implement, one solution would be to create surrogate users for each current user and use sudo to limit the access.

good luck!

kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Oviwan
Honored Contributor

Re: cron permissions

Hey

You can entry every job in root's crontab and execute the job with su - username -c "command". the users can't read the roots crontab but must they be able to read it?...

Regards
TMcB
Super Advisor

Re: cron permissions

thanks everyone for replying - i'll do some testing