Ignore:
Timestamp:
Mar 20, 2014 5:04:44 PM (4 years ago)
Author:
ap@apple.com
Message:

Generalize WebInspector check in maybeInitializeSandboxExtensionHandle().
https://bugs.webkit.org/show_bug.cgi?id=130079
<rdar://problem/16286683>

Reviewed by Anders Carlsson.

  • UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):

Perform an early return for all paths that don't need a sandbox extension due to
access being assumed, not only for WebInspector pages.

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::hasAssumedReadAccessToURL):
(WebKit::WebProcessProxy::checkURLReceivedFromWebProcess):

  • UIProcess/WebProcessProxy.h:

Factored out m_localPathsWithAssumedReadAccess iteration to a public function.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp

    r166017 r166026  
    628628        return false;
    629629
     630    if (m_process->hasAssumedReadAccessToURL(url))
     631        return false;
     632
    630633#if ENABLE(INSPECTOR)
    631     // Don't give the inspector full access to the file system.
    632     if (WebInspectorProxy::isInspectorPage(*this))
    633         return false;
     634    // Inspector resources are in a directory with assumed access.
     635    ASSERT_WITH_SECURITY_IMPLICATION(!WebInspectorProxy::isInspectorPage(*this));
    634636#endif
    635637
Note: See TracChangeset for help on using the changeset viewer.