Title: [275740] branches/safari-611-branch/Source
Revision
275740
Author
repst...@apple.com
Date
2021-04-08 19:23:01 -0700 (Thu, 08 Apr 2021)

Log Message

Cherry-pick r274491. rdar://problem/76374243

    Terminate network process when making new WebProcessPool in Lutron App
    https://bugs.webkit.org/show_bug.cgi?id=223194
    <rdar://74674915>

    Reviewed by Geoff Garen.

    Source/WebCore:

    * platform/RuntimeApplicationChecks.h:
    * platform/cocoa/RuntimeApplicationChecksCocoa.mm:
    (WebCore::IOSApplication::isLutron):
    * platform/cocoa/VersionChecks.h:

    Source/WebKit:

    The Lutron App uses allocation of a new WKProcessPool as a way to stop using old session cookies.
    Since r267763 we keep the session cookies for the lifetime of a WKWebsiteDataStore instead of making a new process for each WKProcessPool.
    Add a quirk for this app until they update to use a new WKWebsiteDataStore or use WKHTTPCookieStore API to clear the cookies properly.
    I manually verified this causes the logging out to succeed.

    * UIProcess/WebProcessPool.cpp:

    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@274491 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

Diff

Modified: branches/safari-611-branch/Source/WebCore/ChangeLog (275739 => 275740)


--- branches/safari-611-branch/Source/WebCore/ChangeLog	2021-04-09 02:22:57 UTC (rev 275739)
+++ branches/safari-611-branch/Source/WebCore/ChangeLog	2021-04-09 02:23:01 UTC (rev 275740)
@@ -1,5 +1,46 @@
 2021-04-08  Russell Epstein  <repst...@apple.com>
 
+        Cherry-pick r274491. rdar://problem/76374243
+
+    Terminate network process when making new WebProcessPool in Lutron App
+    https://bugs.webkit.org/show_bug.cgi?id=223194
+    <rdar://74674915>
+    
+    Reviewed by Geoff Garen.
+    
+    Source/WebCore:
+    
+    * platform/RuntimeApplicationChecks.h:
+    * platform/cocoa/RuntimeApplicationChecksCocoa.mm:
+    (WebCore::IOSApplication::isLutron):
+    * platform/cocoa/VersionChecks.h:
+    
+    Source/WebKit:
+    
+    The Lutron App uses allocation of a new WKProcessPool as a way to stop using old session cookies.
+    Since r267763 we keep the session cookies for the lifetime of a WKWebsiteDataStore instead of making a new process for each WKProcessPool.
+    Add a quirk for this app until they update to use a new WKWebsiteDataStore or use WKHTTPCookieStore API to clear the cookies properly.
+    I manually verified this causes the logging out to succeed.
+    
+    * UIProcess/WebProcessPool.cpp:
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@274491 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2021-03-16  Alex Christensen  <achristen...@webkit.org>
+
+            Terminate network process when making new WebProcessPool in Lutron App
+            https://bugs.webkit.org/show_bug.cgi?id=223194
+            <rdar://74674915>
+
+            Reviewed by Geoff Garen.
+
+            * platform/RuntimeApplicationChecks.h:
+            * platform/cocoa/RuntimeApplicationChecksCocoa.mm:
+            (WebCore::IOSApplication::isLutron):
+            * platform/cocoa/VersionChecks.h:
+
+2021-04-08  Russell Epstein  <repst...@apple.com>
+
         Cherry-pick r272707. rdar://problem/76375033
 
     Use event loop to set title

Modified: branches/safari-611-branch/Source/WebCore/platform/RuntimeApplicationChecks.h (275739 => 275740)


--- branches/safari-611-branch/Source/WebCore/platform/RuntimeApplicationChecks.h	2021-04-09 02:22:57 UTC (rev 275739)
+++ branches/safari-611-branch/Source/WebCore/platform/RuntimeApplicationChecks.h	2021-04-09 02:23:01 UTC (rev 275740)
@@ -115,6 +115,7 @@
 WEBCORE_EXPORT bool isPaperIO();
 WEBCORE_EXPORT bool isCrunchyroll();
 bool isWechat();
+WEBCORE_EXPORT bool isLutron();
 
 } // IOSApplication
 

Modified: branches/safari-611-branch/Source/WebCore/platform/cocoa/RuntimeApplicationChecksCocoa.mm (275739 => 275740)


--- branches/safari-611-branch/Source/WebCore/platform/cocoa/RuntimeApplicationChecksCocoa.mm	2021-04-09 02:22:57 UTC (rev 275739)
+++ branches/safari-611-branch/Source/WebCore/platform/cocoa/RuntimeApplicationChecksCocoa.mm	2021-04-09 02:23:01 UTC (rev 275740)
@@ -452,6 +452,12 @@
     return isWechat;
 }
 
+bool IOSApplication::isLutron()
+{
+    static bool isLutronApp = applicationBundleIsEqualTo("com.lutron.lsb"_s);
+    return isLutronApp;
+}
+
 #endif
 
 } // namespace WebCore

Modified: branches/safari-611-branch/Source/WebCore/platform/cocoa/VersionChecks.h (275739 => 275740)


--- branches/safari-611-branch/Source/WebCore/platform/cocoa/VersionChecks.h	2021-04-09 02:22:57 UTC (rev 275739)
+++ branches/safari-611-branch/Source/WebCore/platform/cocoa/VersionChecks.h	2021-04-09 02:23:01 UTC (rev 275740)
@@ -68,6 +68,7 @@
     FirstWithHTMLDocumentSupportedPropertyNames = DYLD_IOS_VERSION_14_5,
     FirstThatObservesClassProperty = DYLD_IOS_VERSION_14_5,
     FirstWithoutWeChatScrollingQuirk = DYLD_IOS_VERSION_14_5,
+    FirstWithSharedNetworkProcess = DYLD_IOS_VERSION_14_5,
 #elif PLATFORM(MAC)
     FirstWithNetworkCache = DYLD_MACOSX_VERSION_10_11,
     FirstWithExceptionsForDuplicateCompletionHandlerCalls = DYLD_MACOSX_VERSION_10_13,

Modified: branches/safari-611-branch/Source/WebKit/ChangeLog (275739 => 275740)


--- branches/safari-611-branch/Source/WebKit/ChangeLog	2021-04-09 02:22:57 UTC (rev 275739)
+++ branches/safari-611-branch/Source/WebKit/ChangeLog	2021-04-09 02:23:01 UTC (rev 275740)
@@ -1,5 +1,48 @@
 2021-04-08  Russell Epstein  <repst...@apple.com>
 
+        Cherry-pick r274491. rdar://problem/76374243
+
+    Terminate network process when making new WebProcessPool in Lutron App
+    https://bugs.webkit.org/show_bug.cgi?id=223194
+    <rdar://74674915>
+    
+    Reviewed by Geoff Garen.
+    
+    Source/WebCore:
+    
+    * platform/RuntimeApplicationChecks.h:
+    * platform/cocoa/RuntimeApplicationChecksCocoa.mm:
+    (WebCore::IOSApplication::isLutron):
+    * platform/cocoa/VersionChecks.h:
+    
+    Source/WebKit:
+    
+    The Lutron App uses allocation of a new WKProcessPool as a way to stop using old session cookies.
+    Since r267763 we keep the session cookies for the lifetime of a WKWebsiteDataStore instead of making a new process for each WKProcessPool.
+    Add a quirk for this app until they update to use a new WKWebsiteDataStore or use WKHTTPCookieStore API to clear the cookies properly.
+    I manually verified this causes the logging out to succeed.
+    
+    * UIProcess/WebProcessPool.cpp:
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@274491 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2021-03-16  Alex Christensen  <achristen...@webkit.org>
+
+            Terminate network process when making new WebProcessPool in Lutron App
+            https://bugs.webkit.org/show_bug.cgi?id=223194
+            <rdar://74674915>
+
+            Reviewed by Geoff Garen.
+
+            The Lutron App uses allocation of a new WKProcessPool as a way to stop using old session cookies.
+            Since r267763 we keep the session cookies for the lifetime of a WKWebsiteDataStore instead of making a new process for each WKProcessPool.
+            Add a quirk for this app until they update to use a new WKWebsiteDataStore or use WKHTTPCookieStore API to clear the cookies properly.
+            I manually verified this causes the logging out to succeed.
+
+            * UIProcess/WebProcessPool.cpp:
+
+2021-04-08  Russell Epstein  <repst...@apple.com>
+
         Cherry-pick r274325. rdar://problem/76416354
 
     Adopt VM_FLAGS_PERMANENT for the config vm mapping

Modified: branches/safari-611-branch/Source/WebKit/UIProcess/WebProcessPool.cpp (275739 => 275740)


--- branches/safari-611-branch/Source/WebKit/UIProcess/WebProcessPool.cpp	2021-04-09 02:22:57 UTC (rev 275739)
+++ branches/safari-611-branch/Source/WebKit/UIProcess/WebProcessPool.cpp	2021-04-09 02:23:01 UTC (rev 275740)
@@ -326,6 +326,15 @@
     });
 
     updateBackForwardCacheCapacity();
+
+#if PLATFORM(IOS)
+    if (WebCore::IOSApplication::isLutron() && !WebCore::linkedOnOrAfter(WebCore::SDKVersion::FirstWithSharedNetworkProcess)) {
+        callOnMainRunLoop([] {
+            if (WebsiteDataStore::defaultDataStoreExists())
+                WebsiteDataStore::defaultDataStore()->terminateNetworkProcess();
+        });
+    }
+#endif
 }
 
 WebProcessPool::~WebProcessPool()
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to