1

Why are my home folders accessible by other users on the same system by default? I understand that I can change the permission of the home folders but want to know why this happened?

I have done nothing to make the folders "shareable" and yet I can easily navigate to any users home folder using Nemo 2.4.5 and see all their contents.

This is quite a privacy and security flaw and I'm not sure why it has defaulted this way on my system.

Under Users and Groups (items checked =) (both are administrator accounts)

User 1 = adm, cdrom, dip, lpadmin, plugdev, sudo

User 2 = User 2, sudo

Also of note is why User 2 has User 2 clicked but User 1 does not have User 1 clicked. Both accounts appear to behave exactly the same.

Thank you for any tips in this matter.

2 Answers 2

5

The default umask is 022, which allows group and others read permissions (and execute, where applicable) (or 002 if User Private Groups are enabled). If you have a problem with that being the default, file a bug. If you want to change the default, edit /etc/login.defs and change

UMASK       022

to

UMASK       077

And then do:

chmod og-rx -R ~
1
  • I learned something today! Thanks (and upvoted)!
    – Fabby
    Feb 17, 2015 at 7:23
2

If using the graphical interface or the adduser command to create the users, you can modify this in the file /etc/adduser.conf as explained in the manpage, by changing DIR_MODE from 0755 to 0700 or whatever you want.

Also, for useradd, see this answer in SuperUser's forum.

1
  • in terminal sudo chmod 700 /home/user (user is your account name) seems to be a simple and fast fix! thx guys! Feb 13, 2015 at 13:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .