fix home dir perms and owner, add test to catch in the future