Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 7d86b2c8a054e15691ae22c2b6f9ca287858770d
https://github.com/WebKit/WebKit/commit/7d86b2c8a054e15691ae22c2b6f9ca287858770d
Author: Per Arne Vollan <[email protected]>
Date: 2026-08-21 (Fri, 21 Aug 2026)
Changed paths:
M Source/WTF/wtf/FileSystem.h
M Source/WTF/wtf/cocoa/FileSystemCocoa.mm
M Source/WebKit/NetworkProcess/NetworkProcess.cpp
M Source/WebKit/Shared/AuxiliaryProcess.h
M Source/WebKit/Shared/mac/AuxiliaryProcessMac.mm
M Source/WebKit/UIProcess/WebPageProxy.cpp
Log Message:
-----------
Error opening local HTML files from Notes
https://bugs.webkit.org/show_bug.cgi?id=322053
rdar://174169483
Reviewed by Sihui Liu.
Opening a HTML file from the Notes app is failing when the Develop menu is
enabled in Safari.
This is because the storage class of the HTML file on disk is different then
the path Safari
created a sandbox extension for, which is the root of the file system in
developer mode.
Fix this by checking if the file path has a separate storage class, and if so,
don't create
an extension for the root of the file system, but instead create an extension
for the parent
directory of the file. By doing so, the system will not deny the WebContent
process to create
a sandbox extension for the Networking process.
This bug depends on the System Integrity Protection mode, which makes it
non-trivial to
create a test case.
* Source/WTF/wtf/FileSystem.h:
* Source/WTF/wtf/cocoa/FileSystemCocoa.mm:
(WTF::FileSystemImpl::homeDirectory):
* Source/WebKit/Shared/AuxiliaryProcess.h:
* Source/WebKit/Shared/mac/AuxiliaryProcessMac.mm:
(WebKit::populateSandboxInitializationParameters):
(WebKit::AuxiliaryProcess::openDirectoryCacheInvalidated):
(WebKit::AuxiliaryProcess::getHomeDirectory): Deleted.
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::pathHasSeparateStorageClass):
(WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):
Canonical link: https://commits.webkit.org/319627@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications