Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 16
Can I allow a user to have access to all his home files only, no matter what the ownership of the files in his dir ? I mean root can ...
  1. #1
    Just Joined!
    Join Date
    Apr 2008
    Posts
    20

    Ownership levels?

    Can I allow a user to have access to all his home files only, no matter what the ownership of the files in his dir ?
    I mean root can access any file owned by any one, I need to make a super user like that but only in his dir, is it possible?

  2. #2
    Linux Engineer wje_lf's Avatar
    Join Date
    Sep 2007
    Location
    Mariposa
    Posts
    1,192
    No. .
    --
    Bill

    Old age and treachery will overcome youth and skill.

  3. #3
    Just Joined!
    Join Date
    Apr 2008
    Posts
    20
    Thanks.
    But I found the solution:
    It's by execute this command by the user who create the files:
    chmod o+rx

    o = others: users who are not the owner of the file or members of the group.
    chmod - Wikipedia, the free encyclopedia

  4. #4
    Linux Guru
    Join Date
    Nov 2004
    Posts
    6,110
    That was a loaded question , you said "no matter what the ownership of the files in his dir". Actually what you have done is change the access level of the files rather than amend the user to always have access to files in the directory

  5. #5
    Linux Engineer wje_lf's Avatar
    Join Date
    Sep 2007
    Location
    Mariposa
    Posts
    1,192
    Another limitation is that the owner of the files must do that again to every new file he creates later on. I was under the impression that you wanted something that you could set up once and forget, even if new files were added.
    --
    Bill

    Old age and treachery will overcome youth and skill.

  6. #6
    Linux Guru
    Join Date
    Nov 2007
    Location
    Córdoba (Spain)
    Posts
    1,513
    The question was horribly designed. The response that wje_lf gave to the original question is correct.

    You asked for this:

    "How to allow a given user to access all the files on his/her home dir, no matter what permissions/owner the files have"

    Which is impossible.

    And the question you answered on your second post, is this:

    "How to change the permissions of my files, so EVERYONE can access them".

    Which is something completely different and unrelated.

    Note also that there's no need to use the wikipedia to get help about linux commands. That's what man pages are for:

    Code:
    man chmod

  7. #7
    Just Joined!
    Join Date
    Apr 2008
    Posts
    20
    Quote Originally Posted by bigtomrodney View Post
    That was a loaded question
    Right, but the answer was too downed

    wje_lf:
    it better to have it one time, but when you have a newly files, most time it'll be another program files, so we can add that command to the program.

    Can't we add the user to root group or some group like that to have a full access ?
    Note: apache or httpd or php can access another user files

  8. #8
    Just Joined!
    Join Date
    Apr 2008
    Posts
    20
    Quote Originally Posted by i92guboj View Post
    The question was horribly designed. The response that wje_lf gave to the original question is correct.

    You asked for this:

    "How to allow a given user to access all the files on his/her home dir, no matter what permissions/owner the files have"

    Which is impossible.

    And the question you answered on your second post, is this:

    "How to change the permissions of my files, so EVERYONE can access them".

    Which is something completely different and unrelated.

    Note also that there's no need to use the wikipedia to get help about linux commands. That's what man pages are for:

    Code:
    man chmod
    Thanks, but i'm searching for a solution, so I need any way I can do my goal in it.
    The mistake that I have done, is not explane all of my case, because I don't like that people who put there problem and wait for a full solution

    Thanks for "man", I just was googling and found that link in the top of page, I didn't know that the solution will be in chmod.

  9. #9
    Linux Guru
    Join Date
    Nov 2007
    Location
    Córdoba (Spain)
    Posts
    1,513
    Quote Originally Posted by wje_lf View Post
    Another limitation is that the owner of the files must do that again to every new file he creates later on. I was under the impression that you wanted something that you could set up once and forget, even if new files were added.
    Read on umask.

  10. #10
    Linux Guru
    Join Date
    Nov 2007
    Location
    Córdoba (Spain)
    Posts
    1,513
    Quote Originally Posted by kdman View Post
    Right, but the answer was too downed

    wje_lf:
    it better to have it one time, but when you have a newly files, most time it'll be another program files, so we can add that command to the program.

    Can't we add the user to root group or some group like that to have a full access ?
    Note: apache or httpd or php can access another user files
    Not really. The apache daemon runs with a given user id. It can be the user id of your user if you launch it manually, it can be root (gosh, I feel nothing but pity for those running it that way) or it can be it's own custom passwordless user (usually, called "apache").

    The server will only be able to read the files that the user it's running under can read. Nothing more, nothing less. No user land application can bypass the permissions. And apache (nor any other daemon) is an exception.

    If you mean that apache can exec php files even if they are not set +x, then that right. Php files are not system executables, they are interpreted by a php interpreter tied to the web server, so, it's up to this two pieces how to interpret those files. It's not much different of interpreting html, and for that, +r suffices.

Page 1 of 2 1 2 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...