From dbaa03f8a680b598e91d1ee899d5f8b81586a688 Mon Sep 17 00:00:00 2001 From: opa334 Date: Tue, 28 Nov 2023 14:12:45 +0100 Subject: [PATCH] Restore support for apps that have the com.apple.private.security.no-sandbox entitlement --- RootHelper/main.m | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/RootHelper/main.m b/RootHelper/main.m index 52d0e9e..367d213 100644 --- a/RootHelper/main.m +++ b/RootHelper/main.m @@ -622,7 +622,12 @@ int signApp(NSString* appPath) if (noContainerO && [noContainerO isKindOfClass:[NSNumber class]]) { noContainer = [(NSNumber *)noContainerO boolValue]; } - if (!noContainer) { + NSObject *noSandboxO = entitlementsToUse[@"com.apple.private.security.no-sandbox"]; + BOOL noSandbox = NO; + if (noSandboxO && [noSandboxO isKindOfClass:[NSNumber class]]) { + noSandbox = [(NSNumber *)noSandboxO boolValue]; + } + if (!noContainer && !noSandbox) { entitlementsToUse[@"com.apple.private.security.container-required"] = bundleId; } }