I've been poking at this code, because I'm looking at get_tm_used() which reads all of the sparsebundles. I noticed that when I added a stat() call to read the ownership of the Info.plist file, it failed with a permission error since stat() requires execute permission on the path of the file its reading.
Now, I don't know what the permissions -should- be, but wrapping the code with become_root() and unbecome_root() addressed the permission issue. Possibly the developer assumed that each user would be redirected into a private directory where they owned all of the files?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
For the moment I fixed it using "directory perm = 0750" in afp.conf. This seems to work quite well and because we use encrypted disk images it seems not to be a security problem.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I've been poking at this code, because I'm looking at get_tm_used() which reads all of the sparsebundles. I noticed that when I added a stat() call to read the ownership of the Info.plist file, it failed with a permission error since stat() requires execute permission on the path of the file its reading.
Now, I don't know what the permissions -should- be, but wrapping the code with become_root() and unbecome_root() addressed the permission issue. Possibly the developer assumed that each user would be redirected into a private directory where they owned all of the files?
For the moment I fixed it using "directory perm = 0750" in afp.conf. This seems to work quite well and because we use encrypted disk images it seems not to be a security problem.