LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Security (http://www.linuxquestions.org/questions/linux-security-4/)
-   -   Permissions with umask (http://www.linuxquestions.org/questions/linux-security-4/permissions-with-umask-384490/)

NullDevice23 11-18-2005 08:13 PM

[SOLVED] Permissions with umask
 
hi,

if i type

Code:

$ umask 002
$ touch hello
$ ls -l
-rw-rw-r--  1 myname mygrp      0 Nov 19 02:16 hello

The umask is what u subtract from a octal chmod value right? Where is the "x" execute then? I set it to 0 for owner and group, they still dont have the execute permission set.

-> ?? Why

AltF4 11-18-2005 08:27 PM

because by default files are not executable - would be pretty useless to have all text files, jpg files, etc. executable :-)

you have to "chmod +x" or use a program being "clever" enough to know it creates executble files (e.g. gcc :-) to set the "x" bit.


All times are GMT -5. The time now is 09:25 PM.