Mojave: Opt into the Hardened Runtime capability |
||||
Issue descriptionMacOS 10.14 Mojave introduces the Enhanced/Hardened Runtime capability that sets a more restrictive security baseline than a standard macOS app. It is similar to the `codesign -o restrict` flag that Chrome is currently signed with (see issue 523045 and issue 523041 ), but it includes enforcement of more restrictions. Specifically: A) All executable pages must be backed by a valid code signature B) Signature for all libraries, frameworks, and plugins are validated at runtime C) Apps opting in to the new runtime cannot debug other apps or be debugged themselves unless the capability is declared D) Attempts to access protected resources without pre-declaring intent will result in a hard crash For (A) we will most certainly need to create some exceptions due to V8's JITing. We can use the com.apple.security.cs.allow-jit entitlement for that. This will not only affect the renderer but likely also the browser due to the PAC proxy resolver. We also need to ensure that any plugins we load (e.g., Flash) are also signed to not run afoul of (B), but I think that may be already be taken care of. When we tried to enforce this ourselves previously (see issue 497190 ), we ran into issues because printer modules are non-Apple-or-team-ID-signed and have to be loaded into the print dialog in-process. We should investigate what's changed here on 10.14. For signed official builds, (C) already applies. And we will need to do work for (D), for which I've filed issue 850175 . But we'll also need to add the appropriate entitlements: com.apple.security.device.audio-input, com.apple.security.device.camera, com.apple.security.personal-information.location, and potentially com.apple.security.personal-information.photos-library. It is currently unclear if the hardened runtime requires the app also be sandboxed, which would mean sandboxing the browser process. More details here: https://help.apple.com/xcode/mac/current/#/devf87a2ac8f https://developer.apple.com/videos/play/wwdc2018/702/
,
Jun 6 2018
Issue 850201 tracks the unknown/potential prerequisite for sandboxing the browser.
,
Jun 6 2018
,
Dec 6
Another point to reconcile will be the use of mach_override, which is only used to implement cfbundle_blocker. If we want to continue shipping that, I suspect we'll need to grant the com.apple.security.cs.disable-executable-page-protection entitlement. The helper will also need to be granted com.apple.security.cs.disable-library-validation so that it can load Flash.
,
Dec 7
When enabling the hardened runtime in a test app, unless the disable-library-validation entitlement is granted, it appears that Print Dialog Extensions (PDEs) are blocked. Nothing seems to have changed in 10.14 from when we experimented with library validation in issue 497190 .
,
Dec 7
Note that in 10.14, it appears that PDEs aren't loaded into things like TextEdit or Preview, either. Neither of those apps have the hardened runtime flags though, but they may be inheriting the behavior as a result being a platform binary and rootless/SIP.
,
Dec 7
,
Dec 12
Filed rdar://46665082 about PDEs not being loaded. |
||||
►
Sign in to add a comment |
||||
Comment 1 by rsesek@chromium.org
, Jun 6 2018