Is there a way to block a user on a Mac from opening or using Terminal? I'm running macOS 12.4 Monterey.
So I tried doing that. Isn't the way you move an app rather than copy is hold down the Command key and drag it to the folder you want?You could move the application out of the systems application folder and put it in your user accounts application folder.
Terminal has "system" as the only one with read/write permissions. Then it has "wheel" and "everyone" with read-only. Not sure what to change here and not mess something up.ah they changed this is in later versions of Mac OS.
You can also highlight the application and press command + I and set the sharing and permission options for the application.
Screen time doesn't give an option to disable or hide Terminal the way the old Parental Controls did. The best I can do is create and App Limit. But it won't let you set an app limit of zero - the minimum is one minute. So they could get in, run commands and get out and defeat the purpose.Set up content and privacy restrictions in Screen Time on Mac
In Screen Time on your Mac, restrict explicit content, purchases, apps, and downloads.support.apple.com
You could restrict what apps can be run with Screen Time.
So in macOS 12.4 at least, you can choose between a Standard, Admin, or Shared User. No "managed" option.Set the user as a managed user, and remove Terminal from their list of apps.
Other strategies might be effective, too, but you'd have to describe the technical skill level of the person you're trying to block Terminal access for. For example, if they have an admin account and some AppleScript skills, then the things I'm thinking of won't deter them.
This question, like many others regarding security, depends on the answer to the question:
Who are you trying to defend against?
ls -ld /Applications/Utilities/Terminal.app
id
drwxr-xr-x 3 root wheel 96 May 9 16:30 /System/Applications/Utilities/Terminal.app
uid=501(titan) gid=20(staff) groups=20(staff),501(access_bpf),12(everyone),61(localaccounts),701(com.apple.sharepoint.group.1),702(com.apple.sharepoint.group.2),100(_lpoperator),704(com.apple.sharepoint.group.3),705(com.apple.sharepoint.group.4)
You'd think. But surprisingly, you can do all sorts of things via Terminal to Chrome that don't require admin privileges, even if you're a standard user.Set user as non admin. Then he can do in Terminal only what he can do in his user account.
if you are letting him to run as admin, well, that’s not an issue of Terminal, but your wrong security policy.
They don't have admin rights so they aren't able to install anything.Even if you somehow find a way of disabling the Terminal app, can't they just download something like iTerm instead?
Can you give us an example of something they're doing to Chrome? Give us a Terminal command they've used.
you can do something likeIs there a way to block a user on a Mac from opening or using Terminal? I'm running macOS 12.4 Monterey.
echo "exit" >> ~/.zprofile && chmod 544 ~/.zprofile
Uninstall Chrome? It sounds like Chrome is the problem…They don't have admin rights so they aren't able to install anything.
Without getting into specific commands, there are Terminal commands that can change/reset settings in Chrome. And they seem to work whether you're an admin or not.
Only if installing to /Applications. Can install most stuff under a user account (aka the simple drag to install programs). Heck, can run many programs from the installer.They don't have admin rights so they aren't able to install anything.
OP (post #9) says that the kid is required to use Chrome for schoolwork.Uninstall Chrome? It sounds like Chrome is the problem…
Thanks.Code:drwxr-xr-x 3 root wheel 96 May 9 16:30 /System/Applications/Utilities/Terminal.app uid=501(titan) gid=20(staff) groups=20(staff),501(access_bpf),12(everyone),61(localaccounts),701(com.apple.sharepoint.group.1),702(com.apple.sharepoint.group.2),100(_lpoperator),704(com.apple.sharepoint.group.3),705(com.apple.sharepoint.group.4)
id CHILD
ls -l /Users
Are you saying that Terminal commands issued by a non-admin user will change global settings for Chrome when it's used by all other users? Or does it only affect that user's Chrome settings?Without getting into specific commands, there are Terminal commands that can change/reset settings in Chrome. And they seem to work whether you're an admin or not.
if it’s the later, they might be able to lock the users Chrome config files?Finally, could you clarify this:
Are you saying that Terminal commands issued by a non-admin user will change global settings for Chrome when it's used by all other users? Or does it only affect that user's Chrome settings?
If it's the former, then that seems like a serious security flaw. Even if all the Mac accounts are sharing a Chrome profile, that just seems like a design flaw that's asking for trouble.
If it's the latter, i.e. only affecting the user who used the Terminal commands, then at least the problem is limited in scope. It's one thing to alter one's own sandbox, but quite another to alter the sandboxes of everyone else in the world.
It depends on what the Terminal commands are. For example, if Chrome uses theif it’s the later, they might be able to lock the users Chrome config files?
defaults
system in addition to its own files, then things get hairier.No you can’t if Chrome is put into system Applications folder. You can’t change anything there without admin account.You'd think. But surprisingly, you can do all sorts of things via Terminal to Chrome that don't require admin privileges, even if you're a standard user.