⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 277338 in webkit


Ignore:
Timestamp:
May 11, 2021, 1:45:18 PM (5 years ago)
Author:
Ben Nham
Message:

Failing sandbox check for media permissions should not generate a violation report
https://bugs.webkit.org/show_bug.cgi?id=225662

Reviewed by Geoffrey Garen.

We sandbox_check the UIProcess for camera and video permissions. But if the process doesn't
have those permissions, sandbox_check fails and generates an expensive violation report that
task_suspends the process. We need to suppress the reporting with SANDBOX_CHECK_NO_REPORT.

  • UIProcess/Cocoa/MediaPermissionUtilities.mm:

(WebKit::checkSandboxRequirementForType):

Location:
trunk/Source/WebKit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/ChangeLog

    r277336 r277338  
     12021-05-11  Ben Nham  <nham@apple.com>
     2
     3        Failing sandbox check for media permissions should not generate a violation report
     4        https://bugs.webkit.org/show_bug.cgi?id=225662
     5
     6        Reviewed by Geoffrey Garen.
     7
     8        We sandbox_check the UIProcess for camera and video permissions. But if the process doesn't
     9        have those permissions, sandbox_check fails and generates an expensive violation report that
     10        task_suspends the process. We need to suppress the reporting with SANDBOX_CHECK_NO_REPORT.
     11
     12        * UIProcess/Cocoa/MediaPermissionUtilities.mm:
     13        (WebKit::checkSandboxRequirementForType):
     14
    1152021-05-11  Alex Christensen  <achristensen@webkit.org>
    216
  • trunk/Source/WebKit/UIProcess/Cocoa/MediaPermissionUtilities.mm

    r274764 r277338  
    6262            return;
    6363
    64         int result = sandbox_check(getpid(), operation, SANDBOX_FILTER_NONE);
     64        int result = sandbox_check(getpid(), operation, static_cast<enum sandbox_filter_type>(SANDBOX_CHECK_NO_REPORT | SANDBOX_FILTER_NONE));
    6565        if (result == -1)
    6666            WTFLogAlways("Error checking '%s' sandbox access, errno=%ld", operation, (long)errno);
Note: See TracChangeset for help on using the changeset viewer.