Title: [198089] trunk/Source/WebKit2
Revision
198089
Author
[email protected]
Date
2016-03-13 18:44:08 -0700 (Sun, 13 Mar 2016)

Log Message

[Mac] Injected bundle in relocatable WebContent service can’t use XPC services from other relocatable frameworks
https://bugs.webkit.org/show_bug.cgi?id=155414
<rdar://problem/24428418>

Reviewed by Sam Weinig.

* Configurations/DebugRelease.xcconfig:
  Set WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT to NO, because
  engineering builds are ad-hoc signed and therefore can’t have a private entitlement.

* Configurations/WebContent-OSX.entitlements: Added. Includes the XPC domain extension
  entitlement.

* Configurations/WebContentService.xcconfig:
  Set WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT to YES if not already set
  and the framework is relocatable. Set CODE_SIGN_ENTITLEMENTS to the new entitlements file
  if the domain extension entitlement is needed.

* WebKit2.xcodeproj/project.pbxproj: Added reference to new file.

Modified Paths

Added Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (198088 => 198089)


--- trunk/Source/WebKit2/ChangeLog	2016-03-14 01:09:17 UTC (rev 198088)
+++ trunk/Source/WebKit2/ChangeLog	2016-03-14 01:44:08 UTC (rev 198089)
@@ -1,3 +1,25 @@
+2016-03-13  Dan Bernstein  <[email protected]>
+
+        [Mac] Injected bundle in relocatable WebContent service can’t use XPC services from other relocatable frameworks
+        https://bugs.webkit.org/show_bug.cgi?id=155414
+        <rdar://problem/24428418>
+
+        Reviewed by Sam Weinig.
+
+        * Configurations/DebugRelease.xcconfig:
+          Set WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT to NO, because
+          engineering builds are ad-hoc signed and therefore can’t have a private entitlement.
+
+        * Configurations/WebContent-OSX.entitlements: Added. Includes the XPC domain extension
+          entitlement.
+
+        * Configurations/WebContentService.xcconfig:
+          Set WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT to YES if not already set
+          and the framework is relocatable. Set CODE_SIGN_ENTITLEMENTS to the new entitlements file
+          if the domain extension entitlement is needed.
+
+        * WebKit2.xcodeproj/project.pbxproj: Added reference to new file.
+
 2016-03-13  Dean Jackson  <[email protected]>
 
         <attachment> should be a runtime-enabled feature

Modified: trunk/Source/WebKit2/Configurations/DebugRelease.xcconfig (198088 => 198089)


--- trunk/Source/WebKit2/Configurations/DebugRelease.xcconfig	2016-03-14 01:09:17 UTC (rev 198088)
+++ trunk/Source/WebKit2/Configurations/DebugRelease.xcconfig	2016-03-14 01:44:08 UTC (rev 198089)
@@ -50,3 +50,5 @@
 WK_RELOCATABLE_FRAMEWORKS = YES;
 WK_XPC_SERVICE_SUFFIX[sdk=macosx*] = .Development;
 WK_XPC_SERVICE_SUFFIX[sdk=*simulator*] = .Development;
+
+WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT = NO;

Added: trunk/Source/WebKit2/Configurations/WebContent-OSX.entitlements (0 => 198089)


--- trunk/Source/WebKit2/Configurations/WebContent-OSX.entitlements	                        (rev 0)
+++ trunk/Source/WebKit2/Configurations/WebContent-OSX.entitlements	2016-03-14 01:44:08 UTC (rev 198089)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>com.apple.private.xpc.domain-extension</key>
+	<true/>
+</dict>
+</plist>

Modified: trunk/Source/WebKit2/Configurations/WebContentService.xcconfig (198088 => 198089)


--- trunk/Source/WebKit2/Configurations/WebContentService.xcconfig	2016-03-14 01:09:17 UTC (rev 198088)
+++ trunk/Source/WebKit2/Configurations/WebContentService.xcconfig	2016-03-14 01:44:08 UTC (rev 198089)
@@ -25,6 +25,9 @@
 
 WK_XPC_SERVICE_IOS_ENTITLEMENTS_BASE = WebContent-iOS;
 
+CODE_SIGN_ENTITLEMENTS[sdk=macosx*] = $(CODE_SIGN_ENTITLEMENTS_OSX_WITH_XPC_DOMAIN_EXTENSION_$(WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT));
+CODE_SIGN_ENTITLEMENTS_OSX_WITH_XPC_DOMAIN_EXTENSION_YES = Configurations/WebContent-OSX.entitlements;
+
 PRODUCT_NAME = com.apple.WebKit.WebContent$(WK_XPC_SERVICE_SUFFIX);
 INFOPLIST_FILE[sdk=iphone*] = WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-iOS.plist;
 INFOPLIST_FILE[sdk=macosx*] = WebProcess/EntryPoint/mac/XPCService/WebContentService/Info-OSX$(WK_XPC_SERVICE_INFOPLIST_SUFFIX).plist;
@@ -32,3 +35,8 @@
 OTHER_LDFLAGS = $(inherited) $(OTHER_LDFLAGS_VERSIONED_FRAMEWORK_PATH) $(OTHER_LDFLAGS_PLATFORM) $(WK_RELOCATABLE_FRAMEWORKS_LDFLAGS);
 OTHER_LDFLAGS_PLATFORM[sdk=macosx*] = -framework AppKit $(OTHER_LDFLAGS_SHIM_$(WK_LINK_SHIM));
 OTHER_LDFLAGS_SHIM_YES = $(BUILT_PRODUCTS_DIR)/WebProcessShim.dylib;
+
+WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT = $(WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT_$(WK_EMPTY_$(WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT)));
+WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT_ = $(WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT_NO);
+WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT_NO = $(WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT);
+WK_WEBCONTENT_SERVICE_NEEDS_XPC_DOMAIN_EXTENSION_ENTITLEMENT_YES = $(WK_RELOCATABLE_FRAMEWORKS);

Modified: trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj (198088 => 198089)


--- trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj	2016-03-14 01:09:17 UTC (rev 198088)
+++ trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj	2016-03-14 01:44:08 UTC (rev 198089)
@@ -2782,6 +2782,7 @@
 		37A5E01218BBF937000A081E /* _WKActivatedElementInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = _WKActivatedElementInfo.h; sourceTree = "<group>"; };
 		37A64E5418F38E3C00EB30F1 /* _WKInputDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = _WKInputDelegate.h; sourceTree = "<group>"; };
 		37A64E5618F38F4600EB30F1 /* _WKFormInputSession.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = _WKFormInputSession.h; sourceTree = "<group>"; };
+		37B418EB1C9624F20031E63B /* WebContent-OSX.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "WebContent-OSX.entitlements"; sourceTree = "<group>"; };
 		37B5045119EEF31300CE2CF8 /* WKErrorPrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKErrorPrivate.h; sourceTree = "<group>"; };
 		37BEC4DE19491486008B4286 /* CompletionHandlerCallChecker.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CompletionHandlerCallChecker.mm; sourceTree = "<group>"; };
 		37BEC4DF19491486008B4286 /* CompletionHandlerCallChecker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CompletionHandlerCallChecker.h; sourceTree = "<group>"; };
@@ -4229,6 +4230,7 @@
 				5183B3931379F85C00E8754E /* Shim.xcconfig */,
 				1A4F976E100E7B6600637A18 /* Version.xcconfig */,
 				7C0BB9A818DCDE890006C086 /* WebContent-iOS.entitlements */,
+				37B418EB1C9624F20031E63B /* WebContent-OSX.entitlements */,
 				BCACC40E16B0B8A800B6E092 /* WebContentService.xcconfig */,
 				BCB86F4B116AAACD00CE20B7 /* WebKit.xcconfig */,
 				A1EDD2DD1884B9E300BBFE98 /* WebProcessShim.xcconfig */,
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to