nixCraft Linux Forum

nixCraft

Linux Tech Support Forum

/etc/crontab file permissions or ownership can cause problem

This is a discussion on /etc/crontab file permissions or ownership can cause problem within the Linux software forums, part of the Linux Getting Started category; Ok my question is can wrong permissions or ownership on /etc/crontab cause problem? Here is what doc says: There are ...


Go Back   nixCraft Linux Forum > Linux Getting Started > Linux software

Register FAQ Members List Calendar Forgotten your password? Mark Forums Read
  #1 (permalink)  
Old 12-19-2006, 08:06 AM
Member
User
 
Join Date: Feb 2005
Posts: 66
Rep Power: 0
chiku
Default /etc/crontab file permissions or ownership can cause problem

Ok my question is can wrong permissions or ownership on /etc/crontab cause problem?

Here is what doc says:

There are some requirements for /etc/crontab file. Wong file permission can result into weird results or problems.

Requirements of /etc/crontab file permission and ownership:
* File must be owned by root
* File must not be executable
* File must not be writable by any user other than root

If file permission is not correct, use commad
Code:
chown 0:0 /etc/crontab
chmod 0644  /etc/crontab
ll /etc/crontab
Output:
Code:
-rw-r--r--  1 root root 651 2006-07-29 02:14 /etc/crontab
But I am able to run crond on my Dell laptop w/o above requirements. This is weird. Can some one through out some light on this issue
Code:
-rwxrwxrwx  1 rakhi rakhi 651 Dec 19 07:54 crontab
__________________
There's no place like 127.0.0.1
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 12-19-2006, 03:08 PM
Senior Member
User
 
Join Date: Dec 2006
Location: /B!n@ry
My distro: openSuSE 10.2
Posts: 127
Rep Power: 0
B!n@ry
Send a message via MSN to B!n@ry
Default

wrong permissions on this file shall lead to a non-root user from adding a command to run in the file, and then it shall be running with the root permissions which is everything. THIS is really not a good thing to do. Every user must not be able to add his commands to the file /etc/crontab but to his own crontab file which he does that by:
Code:
crantab -e username
__________________
LivE Free 0r DiE
L!nux rul3z aLL
Reply With Quote
  #3 (permalink)  
Old 12-20-2006, 02:57 AM
nixcraft's Avatar
Never say die
User
 
Join Date: Jan 2005
Location: BIOS
My distro: Ubuntu
Posts: 1,060
Rep Power: 10
nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute
Default

As pointed out by bin@ry it is a security risk any one can delete or remove your file even if you are using laptop just fix the problem
__________________
Vivek | My personal blog
Linux Evangelist
Play hard stay cool
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Adding Users in Bulk + Passwords and permissions ricksd2sd Shell scripting 0 04-23-2008 01:20 PM
Ubuntu Linux folder permissions myfoot Ubuntu / Debian 1 12-01-2007 09:03 PM
about crontab darknet Shell scripting 2 01-04-2007 07:01 PM
Secure vsftpd FTP permissions on anonymous user uploads nixcraft Getting started tutorials 6 12-20-2006 03:00 AM
[file.handling] problem fahur Shell scripting 4 10-09-2006 03:59 PM


All times are GMT +5.5. The time now is 07:55 PM.


Powered by vBulletin® Version 3.7.4 - Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36