Subject: Supported macOS containment for a sandboxed worker after controller failure
I'm investigating an Apple Silicon/macOS architecture in which an untrusted, signed, sandboxed worker must be independently containable by a separate trusted supervisor.
The worker needs only a narrow authenticated communication channel. It requires no direct network access, external operational credentials, privileged file access or authority to launch helpers.
I understand that App Sandbox does not inherently prevent child-process creation, and that RLIMIT_NPROC alone does not prevent every form of execution delegation.
Could you clarify:
- Is there a public, supported macOS mechanism to deny all worker-originated subprocess creation and execution delegation at launch, while retaining one restricted communication channel?
- Alternatively, is there a supported mechanism for a surviving supervisor to identify, terminate and positively verify the complete execution domain of a worker, including any descendants, after its controller crashes or is suspended?
- What guarantees and limitations apply to stable identity, process exit, automatic relaunch and loss of the supervisor?
I'm specifically seeking supported operating-system guarantees, not private sandbox profiles, polling, heartbeat inference or best-effort process-tree enumeration.
The goal is to determine whether a bounded synthetic containment experiment is technically justified. No production implementation has been attempted.
First, a general point about sandboxing. I see a bunch of folks implement sandboxing via SBPL and I want to be clear that that’s not supported. See this thread for more about that.
Second, we generally recommend that folks adopt the new es_new_descendants_client mechanism that we added in macOS 27. There have been a lot of threads on the forums about this issue recently, and I recommend that you review them before continuing with this thread.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"