Title: [286017] branches/safari-612.3.6.1-branch/Source
Revision
286017
Author
[email protected]
Date
2021-11-18 11:19:20 -0800 (Thu, 18 Nov 2021)

Log Message

Cherry-pick r285130. rdar://problem/85166839

    [macOS] Opening local html files is failing
    https://bugs.webkit.org/show_bug.cgi?id=232572
    <rdar://81330442>

    Reviewed by Brent Fulgham.

    Source/WebKit:

    On some macOS versions, opening local html files is failing. In order for the WebContent process
    to successfully issue the file extension to the Networking process, the flags for the extension
    in the WebContent process must include the user intent flag when the extension is issued with an
    audit token.

    * Shared/Cocoa/SandboxExtensionCocoa.mm:
    (WebKit::SandboxExtensionImpl::sandboxExtensionForType):

    Source/WTF:

    Declare sandbox flag.

    * wtf/spi/darwin/SandboxSPI.h:

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

Modified Paths

Diff

Modified: branches/safari-612.3.6.1-branch/Source/WTF/ChangeLog (286016 => 286017)


--- branches/safari-612.3.6.1-branch/Source/WTF/ChangeLog	2021-11-18 19:17:47 UTC (rev 286016)
+++ branches/safari-612.3.6.1-branch/Source/WTF/ChangeLog	2021-11-18 19:19:20 UTC (rev 286017)
@@ -1,3 +1,44 @@
+2021-11-18  Russell Epstein  <[email protected]>
+
+        Cherry-pick r285130. rdar://problem/85166839
+
+    [macOS] Opening local html files is failing
+    https://bugs.webkit.org/show_bug.cgi?id=232572
+    <rdar://81330442>
+    
+    Reviewed by Brent Fulgham.
+    
+    Source/WebKit:
+    
+    On some macOS versions, opening local html files is failing. In order for the WebContent process
+    to successfully issue the file extension to the Networking process, the flags for the extension
+    in the WebContent process must include the user intent flag when the extension is issued with an
+    audit token.
+    
+    * Shared/Cocoa/SandboxExtensionCocoa.mm:
+    (WebKit::SandboxExtensionImpl::sandboxExtensionForType):
+    
+    Source/WTF:
+    
+    Declare sandbox flag.
+    
+    * wtf/spi/darwin/SandboxSPI.h:
+    
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@285130 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2021-11-01  Per Arne  <[email protected]>
+
+            [macOS] Opening local html files is failing
+            https://bugs.webkit.org/show_bug.cgi?id=232572
+            <rdar://81330442>
+
+            Reviewed by Brent Fulgham.
+
+            Declare sandbox flag.
+
+            * wtf/spi/darwin/SandboxSPI.h:
+
 2021-11-11  Alan Coon  <[email protected]>
 
         Cherry-pick r285565. rdar://problem/83159358

Modified: branches/safari-612.3.6.1-branch/Source/WTF/wtf/spi/darwin/SandboxSPI.h (286016 => 286017)


--- branches/safari-612.3.6.1-branch/Source/WTF/wtf/spi/darwin/SandboxSPI.h	2021-11-18 19:17:47 UTC (rev 286016)
+++ branches/safari-612.3.6.1-branch/Source/WTF/wtf/spi/darwin/SandboxSPI.h	2021-11-18 19:19:20 UTC (rev 286017)
@@ -62,6 +62,7 @@
 
 extern const uint32_t SANDBOX_EXTENSION_NO_REPORT;
 extern const uint32_t SANDBOX_EXTENSION_CANONICAL;
+extern const uint32_t SANDBOX_EXTENSION_USER_INTENT;
 
 char *sandbox_extension_issue_file(const char *extension_class, const char *path, uint32_t flags);
 char *sandbox_extension_issue_generic(const char *extension_class, uint32_t flags);

Modified: branches/safari-612.3.6.1-branch/Source/WebKit/ChangeLog (286016 => 286017)


--- branches/safari-612.3.6.1-branch/Source/WebKit/ChangeLog	2021-11-18 19:17:47 UTC (rev 286016)
+++ branches/safari-612.3.6.1-branch/Source/WebKit/ChangeLog	2021-11-18 19:19:20 UTC (rev 286017)
@@ -1,3 +1,48 @@
+2021-11-18  Russell Epstein  <[email protected]>
+
+        Cherry-pick r285130. rdar://problem/85166839
+
+    [macOS] Opening local html files is failing
+    https://bugs.webkit.org/show_bug.cgi?id=232572
+    <rdar://81330442>
+    
+    Reviewed by Brent Fulgham.
+    
+    Source/WebKit:
+    
+    On some macOS versions, opening local html files is failing. In order for the WebContent process
+    to successfully issue the file extension to the Networking process, the flags for the extension
+    in the WebContent process must include the user intent flag when the extension is issued with an
+    audit token.
+    
+    * Shared/Cocoa/SandboxExtensionCocoa.mm:
+    (WebKit::SandboxExtensionImpl::sandboxExtensionForType):
+    
+    Source/WTF:
+    
+    Declare sandbox flag.
+    
+    * wtf/spi/darwin/SandboxSPI.h:
+    
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@285130 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2021-11-01  Per Arne  <[email protected]>
+
+            [macOS] Opening local html files is failing
+            https://bugs.webkit.org/show_bug.cgi?id=232572
+            <rdar://81330442>
+
+            Reviewed by Brent Fulgham.
+
+            On some macOS versions, opening local html files is failing. In order for the WebContent process
+            to successfully issue the file extension to the Networking process, the flags for the extension
+            in the WebContent process must include the user intent flag when the extension is issued with an
+            audit token.
+
+            * Shared/Cocoa/SandboxExtensionCocoa.mm:
+            (WebKit::SandboxExtensionImpl::sandboxExtensionForType):
+
 2021-11-16  Kocsen Chung  <[email protected]>
 
         Cherry-pick r283386. rdar://problem/83953959

Modified: branches/safari-612.3.6.1-branch/Source/WebKit/Shared/Cocoa/SandboxExtensionCocoa.mm (286016 => 286017)


--- branches/safari-612.3.6.1-branch/Source/WebKit/Shared/Cocoa/SandboxExtensionCocoa.mm	2021-11-18 19:17:47 UTC (rev 286016)
+++ branches/safari-612.3.6.1-branch/Source/WebKit/Shared/Cocoa/SandboxExtensionCocoa.mm	2021-11-18 19:19:20 UTC (rev 286017)
@@ -115,6 +115,9 @@
         case SandboxExtension::Type::ReadByProcess:
             if (!auditToken)
                 return nullptr;
+#if PLATFORM(MAC)
+            extensionFlags |= SANDBOX_EXTENSION_USER_INTENT;
+#endif
             return sandbox_extension_issue_file_to_process(APP_SANDBOX_READ, path, extensionFlags, *auditToken);
         }
     }
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to