Diff
Modified: trunk/Source/WebKit/ChangeLog (289759 => 289760)
--- trunk/Source/WebKit/ChangeLog 2022-02-14 21:09:48 UTC (rev 289759)
+++ trunk/Source/WebKit/ChangeLog 2022-02-14 21:10:50 UTC (rev 289760)
@@ -1,5 +1,21 @@
2022-02-14 J Pascoe <[email protected]>
+ [WebAuthn] Access group not set in add query for importLocalAuthenticatorCredential
+ https://bugs.webkit.org/show_bug.cgi?id=236469
+ rdar://problem/88783447
+
+ Reviewed by Brent Fulgham.
+
+ In Bug 236311 we added support setting accessGroup, but did not properly set it
+ on the addQuery. This patch fixes that.
+
+ Updated API test to use non-standard accessGroup.
+
+ * UIProcess/API/Cocoa/_WKWebAuthenticationPanel.mm:
+ (+[_WKWebAuthenticationPanel importLocalAuthenticatorWithAccessGroup:credential:error:]):
+
+2022-02-14 J Pascoe <[email protected]>
+
[WebAuthn] Modify _WKWebAuthenticationAssertionResponse according to internal needs
https://bugs.webkit.org/show_bug.cgi?id=236369
rdar://88585811
Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/_WKWebAuthenticationPanel.mm (289759 => 289760)
--- trunk/Source/WebKit/UIProcess/API/Cocoa/_WKWebAuthenticationPanel.mm 2022-02-14 21:09:48 UTC (rev 289759)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/_WKWebAuthenticationPanel.mm 2022-02-14 21:10:50 UTC (rev 289760)
@@ -510,7 +510,7 @@
updateQueryIfNecessary(addQuery.get());
if (accessGroup != nil)
- [query setObject:accessGroup forKey:(__bridge id)kSecAttrAccessGroup];
+ [addQuery setObject:accessGroup forKey:(__bridge id)kSecAttrAccessGroup];
status = SecItemAdd(bridge_cast(addQuery.get()), NULL);
if (status) {
Modified: trunk/Tools/ChangeLog (289759 => 289760)
--- trunk/Tools/ChangeLog 2022-02-14 21:09:48 UTC (rev 289759)
+++ trunk/Tools/ChangeLog 2022-02-14 21:10:50 UTC (rev 289760)
@@ -1,3 +1,19 @@
+2022-02-14 J Pascoe <[email protected]>
+
+ [WebAuthn] Access group not set in add query for importLocalAuthenticatorCredential
+ https://bugs.webkit.org/show_bug.cgi?id=236469
+ rdar://problem/88783447
+
+ Reviewed by Brent Fulgham.
+
+ Updated API test to use non-standard access group.
+
+ * TestWebKitAPI/Configurations/TestWebKitAPI-iOS.entitlements:
+ * TestWebKitAPI/Configurations/TestWebKitAPI-macOS-internal.entitlements:
+ * TestWebKitAPI/Configurations/TestWebKitAPI-macOS.entitlements:
+ * TestWebKitAPI/Tests/WebKitCocoa/_WKWebAuthenticationPanel.mm:
+ (TestWebKitAPI::TEST):
+
2022-02-14 Jonathan Bedard <[email protected]>
[EWS] Rebase PRs on tip of branch (Follow-up fix)
Modified: trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-iOS.entitlements (289759 => 289760)
--- trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-iOS.entitlements 2022-02-14 21:09:48 UTC (rev 289759)
+++ trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-iOS.entitlements 2022-02-14 21:10:50 UTC (rev 289760)
@@ -4,6 +4,7 @@
<dict>
<key>keychain-access-groups</key>
<array>
+ <string>com.apple.TestWebKitAPIAlternate</string>
<string>com.apple.TestWebKitAPI</string>
</array>
<key>com.apple.developer.WebKit.ServiceWorkers</key>
Modified: trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-macOS-internal.entitlements (289759 => 289760)
--- trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-macOS-internal.entitlements 2022-02-14 21:09:48 UTC (rev 289759)
+++ trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-macOS-internal.entitlements 2022-02-14 21:10:50 UTC (rev 289760)
@@ -14,6 +14,7 @@
<true/>
<key>keychain-access-groups</key>
<array>
+ <string>com.apple.TestWebKitAPIAlternate</string>
<string>com.apple.TestWebKitAPI</string>
</array>
<key>com.apple.security.temporary-exception.sbpl</key>
Modified: trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-macOS.entitlements (289759 => 289760)
--- trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-macOS.entitlements 2022-02-14 21:09:48 UTC (rev 289759)
+++ trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPI-macOS.entitlements 2022-02-14 21:10:50 UTC (rev 289760)
@@ -4,6 +4,7 @@
<dict>
<key>keychain-access-groups</key>
<array>
+ <string>com.apple.TestWebKitAPIAlternate</string>
<string>com.apple.TestWebKitAPI</string>
</array>
<key>com.apple.private.webkit.webpush</key>
Modified: trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/_WKWebAuthenticationPanel.mm (289759 => 289760)
--- trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/_WKWebAuthenticationPanel.mm 2022-02-14 21:09:48 UTC (rev 289759)
+++ trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/_WKWebAuthenticationPanel.mm 2022-02-14 21:10:50 UTC (rev 289760)
@@ -83,6 +83,7 @@
static String testUserEntityBundleBase64 = "omJpZEoAAQIDBAUGBwgJZG5hbWVkSm9obg=="; // { "id": h'00010203040506070809', "name": "John" }
static String webAuthenticationPanelSelectedCredentialName;
static String testWebKitAPIAccessGroup = "com.apple.TestWebKitAPI";
+static String testWebKitAPIAlternateAccessGroup = "com.apple.TestWebKitAPIAlternate";
static bool laContextRequested = false;
@interface TestWebAuthenticationPanelDelegate : NSObject <_WKWebAuthenticationPanelDelegate>
@@ -2271,6 +2272,7 @@
auto *credentials = [_WKWebAuthenticationPanel getAllLocalAuthenticatorCredentialsWithAccessGroup:testWebKitAPIAccessGroup];
EXPECT_NOT_NULL(credentials);
EXPECT_EQ([credentials count], 1lu);
+ EXPECT_EQ([[_WKWebAuthenticationPanel getAllLocalAuthenticatorCredentialsWithAccessGroup:testWebKitAPIAlternateAccessGroup] count], 0lu);
EXPECT_NOT_NULL([credentials firstObject]);
NSError *error = nil;
@@ -2280,11 +2282,11 @@
EXPECT_EQ([[_WKWebAuthenticationPanel getAllLocalAuthenticatorCredentialsWithAccessGroup:testWebKitAPIAccessGroup] count], 0lu);
- auto credentialId = [_WKWebAuthenticationPanel importLocalAuthenticatorWithAccessGroup:testWebKitAPIAccessGroup credential:exportedKey error:&error];
+ auto credentialId = [_WKWebAuthenticationPanel importLocalAuthenticatorWithAccessGroup:testWebKitAPIAlternateAccessGroup credential:exportedKey error:&error];
EXPECT_WK_STREQ([[credentials firstObject][_WKLocalAuthenticatorCredentialIDKey] base64EncodedStringWithOptions:0], [credentialId base64EncodedStringWithOptions:0]);
- EXPECT_EQ([[_WKWebAuthenticationPanel getAllLocalAuthenticatorCredentialsWithAccessGroup:testWebKitAPIAccessGroup] count], 1lu);
-
+ EXPECT_EQ([[_WKWebAuthenticationPanel getAllLocalAuthenticatorCredentialsWithAccessGroup:testWebKitAPIAccessGroup] count], 0lu);
+ EXPECT_EQ([[_WKWebAuthenticationPanel getAllLocalAuthenticatorCredentialsWithAccessGroup:testWebKitAPIAlternateAccessGroup] count], 1lu);
cleanUpKeychain("example.com");
}