LinuxQuestions.org
Help answer threads with 0 replies.
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 08-27-2002, 06:53 PM   #1
sourian
LQ Newbie
 
Registered: Mar 2002
Distribution: RedHat, Mandrake
Posts: 29

Rep: Reputation: 15
Question default user permision


don't know if this is the right place to ask, but here I go:

I installed Bastille Linux on a redhat 7.3. The problem is that although I said no at umask question, so default 002 should be preserved, when i try to create a new file with a user, the permisions are set at 664...pretty annoying if you use the system as web development platform...

Now I checked /etc/profile and 002 is the setting there. No .bashrc in $HOME found...

What am I doing wrong?!

Please advise.
 
Old 08-27-2002, 09:18 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,417
Blog Entries: 55

Rep: Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623
When you add an account ~/.bash* files are provided from /etc/skel (if it's there). ~/.bash_profile calls ~/.bashrc and ~/.bash_login, and ~/.bashrc calls /etc/bashrc at the end. If it ain't there just make one.
Btw, if you don't care for files readable for other users a mask of 002 is ok, but if you're on a one-user-per-group scheme then 027 (max perms 0750) will do better me thinks.
 
Old 08-28-2002, 12:33 PM   #3
Sixpax
Member
 
Registered: Mar 2002
Distribution: Mandrake 8.1
Posts: 386

Rep: Reputation: 31
You aren't doing anything wrong... a umask of 002 equates to 664 permissions.

What permission do you want on new files?
 
Old 08-29-2002, 01:22 AM   #4
sourian
LQ Newbie
 
Registered: Mar 2002
Distribution: RedHat, Mandrake
Posts: 29

Original Poster
Rep: Reputation: 15
I think 755 is the one I am looking for...

Bu isn't this calculated by this: 777 - 022 = 755?

So why 002 is 664? Shouldn't be 777 - 002 = 775?

I don't understand...from what I've read on the net this should be it...

...hmmm...have to so more...

regards,
sourian
 
Old 08-29-2002, 06:13 AM   #5
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,417
Blog Entries: 55

Rep: Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623
AFAIK, unless product of you compiling stuff, or if permissions are retained when unpacking files files aren't *created* with max perms of 0775.

// Note: I'm grafting this to /General, IMO I can't see any security-related question, and I gotta clean up more.

Last edited by unSpawn; 08-29-2002 at 09:11 AM.
 
Old 08-29-2002, 11:49 AM   #6
Sixpax
Member
 
Registered: Mar 2002
Distribution: Mandrake 8.1
Posts: 386

Rep: Reputation: 31
Files you create will not have the execute permission bit set, only directories do this. You have to set that bit manually on files.

So 002 does equate to 775 for directories and 664 for files.

As you stated though, the umask you want is 022.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
User Permision? And Logoff? amer_58 Linux - Newbie 4 03-14-2005 11:35 AM
user with root permision imsajjadali Red Hat 2 01-20-2004 07:00 AM
problen trying to change my stable to unestable, root user not have permision mie2 Linux - Newbie 0 11-21-2003 04:10 PM
User permision problems e1000 Slackware 6 11-06-2003 12:41 AM
file permision alexr186 Linux - Software 4 10-12-2003 08:56 PM

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

All times are GMT -5. The time now is 09:54 AM.

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