Protect /home from prying eyes

This tip is especially important if you allow your clients SSH access. By default /home permissions are set to 755 which allows any user to cd /home and then list all of the user folders with ls -lah. This may not sound like too big of a security issue. However, if they’re a hacker or just being curious they now have a full list of every username within the system. To resolve this you should update the permissions on the /home folder. This fix has been tested on cpanel servers, DSM servers, Plesk, etc… without any problems.


chmod 751 /home;

Then login as a non-root user and you will be unable to list the folders in /home.

Leave a Reply

You must be logged in to post a comment.