Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 15
I just removed the 'write' permission for owner, group and others, but I still can write to the file if I'm logged in as 'root'. This makes it impossible to ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux Newbie
    Join Date
    Oct 2004
    Posts
    139

    file permissions don't work when running as 'root'


    I just removed the 'write' permission for owner, group and others, but I still can write to the file if I'm logged in as 'root'. This makes it impossible to prevent accidental overwriting of a file when logged in as 'root'.

  2. #2
    Linux User
    Join Date
    Jul 2004
    Location
    USA, Michigan, Detroit
    Posts
    329
    That is correct that is one of the reasons you should not be logged in as root and do maintenance task throught the use of
    Code:
    su -
    and
    Code:
    sudo
    Long live the revolution!
    Have a nice day.
    If you want real change vote Libertarian!

  3. #3
    Just Joined!
    Join Date
    Jan 2005
    Location
    Ohio, USA
    Posts
    15
    Haha! They were talking about that issue on another board. I stick to staying off of root except when totally necessary for fear of phucking something up.

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Newbie
    Join Date
    Oct 2004
    Posts
    139
    Quote Originally Posted by copycon
    That is correct that is one of the reasons you should not be logged in as root and do maintenance task throught the use of
    Code:
    su -
    and
    Code:
    sudo
    But why shouldn't it work? The Windows NT/XP ACL's work even when running as Administrator, so it is possible to prevent accdental overwriting of a file. Logging in as a super user should not bypass file permissions, but has the right to change it. I hope this bug would be fixed in future Linux kernel releases.

  6. #5
    Linux User
    Join Date
    Jul 2004
    Location
    USA, Michigan, Detroit
    Posts
    329
    It will never be fixed as it is not a bug. *nixes have always worked this way and most likely always will.
    Long live the revolution!
    Have a nice day.
    If you want real change vote Libertarian!

  7. #6
    Linux Guru
    Join Date
    May 2004
    Location
    forums.gentoo.org
    Posts
    1,817
    Quote Originally Posted by user222
    I hope this bug would be fixed in future Linux kernel releases.
    So a bug is when the OS gives complete control to the system administrator without idiot-box warnings? Linux is many things, but idiot proof it is not. And with luck, it will never be, at least until the release of Windows Lx.
    /IMHO
    //got nothin'
    ///this use to look better

  8. #7
    Linux Engineer
    Join Date
    Nov 2004
    Location
    Montreal, Canada
    Posts
    1,267
    Quote Originally Posted by drakebasher
    Quote Originally Posted by user222
    I hope this bug would be fixed in future Linux kernel releases.
    So a bug is when the OS gives complete control to the system administrator without idiot-box warnings? Linux is many things, but idiot proof it is not. And with luck, it will never be, at least until the release of Windows Lx.
    I second this... Isnt idiot proof...
    you should NEVER be loged in as root,
    second, root is an admin, and AS to be able to do whatever he wants.
    when working with certain file, either change the file permission your working on temporaly to make your user make the mods, or issue an su command, and then change from terminal
    \"Meditative mind\'s is like a vast ocean... whatever strikes the surface, the bottom stays calm\" - Dalai Lama
    \"Competition ultimatly comes down to one thing... a loser and a winner.\" - Ugo Deschamps

  9. #8
    Linux Newbie
    Join Date
    Oct 2004
    Posts
    139
    Quote Originally Posted by copycon
    It will never be fixed as it is not a bug. *nixes have always worked this way and most likely always will.
    If this strange bug exists in all the *NIX'es, then all the *NIX'es should get it fixed. It's a very big problem, especially when running Linux in single-user mode.

  10. #9
    Linux Newbie
    Join Date
    Oct 2004
    Posts
    139
    Quote Originally Posted by UgoDeschamps
    I second this... Isnt idiot proof...
    you should NEVER be loged in as root,
    second, root is an admin, and AS to be able to do whatever he wants.
    when working with certain file, either change the file permission your working on temporaly to make your user make the mods, or issue an su command, and then change from terminal
    I like to run Linux in single-user mode, so it's a big problem. (I didn't even create a normal, non-root user account.)

  11. #10
    Linux Engineer
    Join Date
    Nov 2004
    Location
    Montreal, Canada
    Posts
    1,267
    Quote Originally Posted by user222
    I like to run Linux in single-user mode, so it's a big problem.
    we'll mate... first its not a bug, a user should not have any rights, this is windows world and it will NEVER be applied to linux or unix, it's the way it's build. If you like to have trojan, viruses and other crap doing whatever they want when logued in root, thats your choice, but to not complain that this is a bug, it is the way its built and we all like it for that.

    you better stay with windows if unsafe environment is what your looking for
    \"Meditative mind\'s is like a vast ocean... whatever strikes the surface, the bottom stays calm\" - Dalai Lama
    \"Competition ultimatly comes down to one thing... a loser and a winner.\" - Ugo Deschamps

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
  •