LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-13-2005, 05:51 AM   #1
asif mushtaq
LQ Newbie
 
Registered: Jul 2005
Posts: 4

Rep: Reputation: 0
how to fix file and directory permissions


Is there anyway in linux to fix the permissions for files and directories. What i mean is that let's say i want any file created to have 2775 permissions assciated with it no matter where and who created the file. Is there a way?
 
Old 07-13-2005, 08:09 AM   #2
fiero
LQ Newbie
 
Registered: Jul 2005
Location: India
Distribution: Red Hat
Posts: 4

Rep: Reputation: 0
Unhappy

You cannot untill you get the write permission to all the directories in the root ( / ).
Once you have write permission, you can change the file creation mask setting.

$umask 5002

Then any file u create will have the permission ! (5002) i.e logical not of ( 5002 ).

Try it then come back.
 
Old 07-13-2005, 11:51 PM   #3
asif mushtaq
LQ Newbie
 
Registered: Jul 2005
Posts: 4

Original Poster
Rep: Reputation: 0
Thanks for your comment. I have already tried the umask thing but the problem with the it is that it doesn't fixes the permissions but rather specifies which permissions are allowed and which are not.
For example if i set umask to 5002 then any permissions could be set except write permission for "others" and "suid" and "sticky bit" permissions. This makes for example 2550 perfectly acceptable.
What i need is a way of totally fix the permissions so that what i specify is what will be set for every folder or file and nobody could change it.

Last edited by asif mushtaq; 07-14-2005 at 12:05 AM.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
File/Directory Permissions waynevnc Debian 1 05-23-2005 04:23 PM
Permissions, File, Directory access tHcnunz Linux - Newbie 3 03-26-2004 09:25 AM
How do i fix this open_basedir restriction in effect. File is in wrong directory DropHit Linux - Software 2 02-26-2004 06:28 PM
File and Directory permissions plasmapudding Red Hat 3 09-09-2003 10:26 AM
Directory and file permissions ryan Linux - Security 2 12-06-2000 12:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 10:57 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration