Go back to 755 permission on per-user directories

700 is pointless since the store is world-readable anyway. And
per-user/root/channels must be world-readable.

(cherry picked from commit d7bae5680fc26303acb9a9ee1a202f537841a624)
This commit is contained in:
Eelco Dolstra 2019-10-09 19:55:05 +02:00
parent 1c10f739eb
commit 7c4589854b
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE

View file

@ -1441,7 +1441,7 @@ void LocalStore::createUser(const std::string & userName, uid_t userId)
fmt("%s/gcroots/per-user/%s", stateDir, userName)
}) {
createDirs(dir);
if (chmod(dir.c_str(), 0700) == -1)
if (chmod(dir.c_str(), 0755) == -1)
throw SysError("changing permissions of directory '%s'", dir);
if (chown(dir.c_str(), userId, -1) == -1)
throw SysError("changing owner of directory '%s'", dir);