(This is just experimenting for educational purposes.)
I'm the admin of the computer and I have SIP disabled. I wish to imitate iOS restrictions on macOS by prohibiting access (to one other specific user account, not me) to all directories except for 'Downloads' of their equivalent 'Users' folder.
Yes, the apps they launch can freely read/write from/to 'Library' and other system-related files as they normally would, but the user just never gets to access those directories (pretty much like iOS minus the sandboxed app-data)
When using Finder (or any other file browser) they can only access their Downloads folder.
Managing their system (installing/uninstalling apps etc.) is of lesser importance as I, the admin, can do it for them when asked.
I think I can implement this by applying a 'No Access' rule to their user account for all directories, which attaches a red flag icon to the folder and does not allow one to access it when clicked.
Instead of going through every single folder to do this with cmd+I
, can I do this with Terminal for all directories minus 'Downloads'?
Terminal
with thechmod
command. It would mean doing something likechmod u-rw Documents Music Pictures Movies <any-folder>
. Theu-rwx
tells the command to remove read/write/execute access to the directory only for the user. To add back any specific permission for the user, you would usechmod u+...
where...
is amongr
w
x
. Does it help ? More on permissions and groupstestuser01
. What is the exact command(s) I need to type, in order to achieve what I asked for in the OP?man chmod
might be helpful here./System
) ? That might prove impossible (unless it causes glitches to the whole system). Also, what about folders created after the initial configuration by 3rd party programs, such as hidden folders (like~/.dropbox
for instance) ? changing their permissions would require work after the initial config. Is that also part of what you want ? (otherwise the user could stillCmd+Maj+.
to show hidden stuffs.