Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 3b08a55102c5ec79db58f6aec9d18056b86c5425
https://github.com/WebKit/WebKit/commit/3b08a55102c5ec79db58f6aec9d18056b86c5425
Author: Brian Weinstein <[email protected]>
Date: 2024-04-09 (Tue, 09 Apr 2024)
Changed paths:
M
Source/WebKit/UIProcess/Extensions/Cocoa/API/WebExtensionContextAPITabsCocoa.mm
M Source/WebKit/UIProcess/Extensions/Cocoa/WebExtensionTabCocoa.mm
M Tools/TestWebKitAPI/Tests/WebKitCocoa/WKWebExtensionAPITabs.mm
Log Message:
-----------
Fix an issue with the background page trying to message full page extension
content
https://bugs.webkit.org/show_bug.cgi?id=272362
rdar://125996453
Reviewed by Timothy Hatcher.
When an extension was trying to send a message from a background page to a tab
with full page extension content, we were treating
the message as going to a content script and sending it to a non-main world,
which led to a crash.
Additionally, we want to block an extension from sending a message to a tab
showing full page content for a different extension. One
extension should have no idea about another's content.
*
Source/WebKit/UIProcess/Extensions/Cocoa/API/WebExtensionContextAPITabsCocoa.mm:
(WebKit::WebExtensionContext::tabsSendMessage):
(WebKit::WebExtensionContext::tabsConnect):
* Source/WebKit/UIProcess/Extensions/Cocoa/WebExtensionTabCocoa.mm:
(WebKit::WebExtensionTab::extensionHasPermission const):
* Tools/TestWebKitAPI/Tests/WebKitCocoa/WKWebExtensionAPITabs.mm:
(TestWebKitAPI::TEST(WKWebExtensionAPITabs,
SendMessageFromBackgroundPageToFullPageExtensionContent)):
Canonical link: https://commits.webkit.org/277240@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes