1

I have many Linux servers each containing many users. Users can execute any command they want. They can also upload new scripts / programs and run them. What bother me is that some users go outside of their homes and start to look at other users homes or system folders like /etc /var etc. I don’t want them to be able to look at the host configurations files and start to hack.

I just want them to be able to access to their own homes, execute scripts in their homes and nothing more.

There is some solutions on internet like chroot but that come most of the time with other problems that needed to be solve.

I was wondering if it is just possible to remove “others” permission on all those system folders like /etc / var etc.. without breaking my linux host. I already did the same with my users homes and it works perfectly.

Thanks for your helps !

5
  • 2
    No, it's not possible to do that for entire root directories, since users are required to have access to them to, for example, run programs. Jan 26, 2018 at 21:38
  • Yes i understand but is it really safe to allow linux users to be able to read /etc/passwd and other configurations files on /etc ? Or get access to /var/log etc.. This allow users to start digging and that really afraid me.
    – Think
    Jan 26, 2018 at 21:44
  • Yes, it's generally safe to allow them to read /etc/passwd since the password hashes are stored in /etc/shadow, which isn't readable by everyone. Security-critical log files in /var/log are already not readable by everyone. Try reading /var/log/kern.log without sudo. As far as configuration files, you might be able to restrict those to the user running the server or whatever in some instances. Jan 26, 2018 at 21:47
  • Thanks for your help. So i will just remove others permissions from homes and let users access the system files.
    – Think
    Jan 27, 2018 at 0:05
  • @ChaiT.Rex Your first comment is an answer. Please post one, ping me here and I'll come back and upvote...
    – Fabby
    Jan 29, 2018 at 23:05

0

You must log in to answer this question.

Browse other questions tagged .