Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(966)

Unified Diff: Source/core/fetch/FetchRequest.h

Issue 47923008: Block execution of failed 'crossorigin' <script>s. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebased Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/dom/ScriptLoader.cpp ('k') | Source/core/fetch/FetchRequest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/fetch/FetchRequest.h
diff --git a/Source/core/fetch/FetchRequest.h b/Source/core/fetch/FetchRequest.h
index f9139377fb5e29db6b14f3947155bb2588d423e5..1954cedbeef01b17e7bcb548547bcca156c11f28 100644
--- a/Source/core/fetch/FetchRequest.h
+++ b/Source/core/fetch/FetchRequest.h
@@ -39,6 +39,7 @@ class SecurityOrigin;
class FetchRequest {
public:
enum DeferOption { NoDefer, DeferredByClient };
+ enum OriginRestriction { UseDefaultOriginRestrictionForType, RestrictToSameOrigin };
explicit FetchRequest(const ResourceRequest&, const AtomicString& initiator, const String& charset = String(), ResourceLoadPriority = ResourceLoadPriorityUnresolved);
FetchRequest(const ResourceRequest&, const AtomicString& initiator, const ResourceLoaderOptions&);
@@ -58,7 +59,9 @@ public:
DeferOption defer() const { return m_defer; }
void setDefer(DeferOption defer) { m_defer = defer; }
void setContentSecurityCheck(ContentSecurityPolicyCheck contentSecurityPolicyOption) { m_options.contentSecurityPolicyOption = contentSecurityPolicyOption; }
- void setPotentiallyCrossOriginEnabled(SecurityOrigin*, StoredCredentials);
+ void setCrossOriginAccessControl(SecurityOrigin*, StoredCredentials);
+ OriginRestriction originRestriction() const { return m_originRestriction; }
+ void setOriginRestriction(OriginRestriction restriction) { m_originRestriction = restriction; }
private:
ResourceRequest m_resourceRequest;
@@ -67,6 +70,7 @@ private:
ResourceLoadPriority m_priority;
bool m_forPreload;
DeferOption m_defer;
+ OriginRestriction m_originRestriction;
};
} // namespace WebCore
« no previous file with comments | « Source/core/dom/ScriptLoader.cpp ('k') | Source/core/fetch/FetchRequest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698