Live data from Hacker News

macOS's Little-Known Command-Line Sandboxing Tool (2025)

igorstechnoclub.com

41–50 of 96 posts

Re: macOS's Little-Known Command-Line Sandboxing Tool (2025)

#41
post #33
post #8

Interesting config used a Scheme-like format. Any ideas on how that came to be?

Technically, it’s not just Scheme-like but literally a Scheme interpreter (TinyScheme). However, the Scheme isn’t being executed to make individual sandboxing decisions. It’s just executed once while parsing the config, to build up a binary sandbox definition which is what the kernel ultimately uses to make decisions (using a much more limited-purpose, non-Turing-complete execution engine).

Do we know that engine is not Turing-complete for sure?

Re: macOS's Little-Known Command-Line Sandboxing Tool (2025)

#44
post #32

Earlier quoted context omitted.

Does anyone have any details regarding the deprecation? I wonder why Apple made this decision.

I don’t know if there are problems with this tool, but the App Sandbox is very configurable and every app store app is in one. It doesn’t make sense to maintain two different complex sandboxing solutions.

If swift package manager is using it (I believe it is based on some of the error messages I occasionally see from it), deprecating it is difficult, since SPM is not distributed as an App Store app.

Re: macOS's Little-Known Command-Line Sandboxing Tool (2025)

#45

Earlier quoted context omitted.

I wonder how many major applications and tools depend on sandbox-exec today despite that depreciation, IIRC I can think of the Codex CLI and Swift Package Manager.

Claude, Firefox, safari, chrome, etc etc etc etc Basically everyone who has to care about security on the Mac.

Bazel as well.

Re: macOS's Little-Known Command-Line Sandboxing Tool (2025)

#46
If Apple wanted to win back some serous credibility in the AI field there are two very low hanging fruit that they could use:

- Announce that they are no longer going to deprecate sandbox-exec and instead publish detailed documentation for it

- Add a reliable "select all" option to the iOS copy/paste menu

Re: macOS's Little-Known Command-Line Sandboxing Tool (2025)

#47

It drives me nuts that sandbox-exec has "sandbox" in the name, since it's nothing like a real sandbox, and much closer to something like a high-level seccomp, and not much to do with "App Sandboxes" which is a distinct macOS feature. IMO a real sandbox let's a program act how it wishes without impacting anything outside the sandbox. In reality many of these tools just cause hard failures when attempting to cross the…

Sandbox-exec covers everything I personally expect from a sandbox:

- controls which files the process can read and write

- controls what network access the process is allowed

Re: macOS's Little-Known Command-Line Sandboxing Tool (2025)

#48
post #46

If Apple wanted to win back some serous credibility in the AI field there are two very low hanging fruit that they could use: - Announce that they are no longer going to deprecate sandbox-exec and instead publish detailed documentation for it - Add a reliable "select all" option to the iOS copy/paste menu

[dead]

Re: macOS's Little-Known Command-Line Sandboxing Tool (2025)

#49
post #32

Earlier quoted context omitted.

Does anyone have any details regarding the deprecation? I wonder why Apple made this decision.

There’s not that much detail. A few comments in 2019 from a DTS person indicated that Apple didn’t really anticipate people shipping on this in volume. My guess is they want to dissuade people from using it. They can’t immediately just do away with it because a bunch of their first party apps use it (entitlements don’t cut it). It’s a weird space.

> a DTS person

Quinn the Eskimo, no doubt. I'm convinced he or she is the only actual human being providing developer technical support at Apple. Certainly the only one I've ever successfully communicated with. Support tickets go to robots who are incapable of providing relevant answers. Maybe Quinn is an alias with a team of humans behind it, but I don't think so. I've had him or her take forum posts to private e-mail and it does seem like a single person.

Unfortunately, even Quinn is fully at the mercy of Apple's internal bureaucracy, which is quite formidable.

Post reply on HN