Unix users and permissions and how they interact with web files.
Posted
by Columbo
on Stack Overflow
See other posts from Stack Overflow
or by Columbo
Published on 2010-05-18T10:48:35Z
Indexed on
2010/05/18
10:51 UTC
Read the original article
Hit count: 476
Hello,
When you issue the command ls in Linux you get this sort of thing:
drwxr--r-- 1 fred editors 4096 drafts
-rw-r--r-- 1 fred editors 30405 file1.php
-r-xr-xr-x 1 fred fred 8460 file2.php
I know that the rwxrwxrwx are the read, write and execute permissions for the current user. And I think I know that 'fred' is the user who owns the file. So I assume fred can write to file1 but no one else can. But what is the extra bit 'editors' and what is the difference between file1 and file2 with respect to one having an ownership of 'fred editors' and the other 'fred fred'?
Also if a web user connects to one of the files, what is their user name and where is this decided? If the server decided that user connecting from the web was going to be fred, does this mean any web user could write to file1?
Any information welcomed, I am resaerching this but just getting confused. Thanks
© Stack Overflow or respective owner