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

Side by Side Diff: third_party/WebKit/Source/core/loader/DocumentLoader.h

Issue 2022083002: Move 'frame-src' CSP checks into FrameFetchContext. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: redirects Created 4 years, 6 months 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
3 * Copyright (C) 2011 Google Inc. All rights reserved. 3 * Copyright (C) 2011 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 void setReplacesCurrentHistoryItem(bool replacesCurrentHistoryItem) { m_repl acesCurrentHistoryItem = replacesCurrentHistoryItem; } 101 void setReplacesCurrentHistoryItem(bool replacesCurrentHistoryItem) { m_repl acesCurrentHistoryItem = replacesCurrentHistoryItem; }
102 102
103 bool isCommittedButEmpty() const { return m_state == Committed; } 103 bool isCommittedButEmpty() const { return m_state == Committed; }
104 104
105 void setSentDidFinishLoad() { m_state = SentDidFinishLoad; } 105 void setSentDidFinishLoad() { m_state = SentDidFinishLoad; }
106 bool sentDidFinishLoad() const { return m_state == SentDidFinishLoad; } 106 bool sentDidFinishLoad() const { return m_state == SentDidFinishLoad; }
107 107
108 NavigationType getNavigationType() const { return m_navigationType; } 108 NavigationType getNavigationType() const { return m_navigationType; }
109 void setNavigationType(NavigationType navigationType) { m_navigationType = n avigationType; } 109 void setNavigationType(NavigationType navigationType) { m_navigationType = n avigationType; }
110 110
111 void startLoadingMainResource(); 111 void startLoadingMainResource(ContentSecurityPolicyDisposition);
112 112
113 void acceptDataFromThreadedReceiver(const char* data, int dataLength, int en codedDataLength); 113 void acceptDataFromThreadedReceiver(const char* data, int dataLength, int en codedDataLength);
114 DocumentLoadTiming& timing() { return m_documentLoadTiming; } 114 DocumentLoadTiming& timing() { return m_documentLoadTiming; }
115 const DocumentLoadTiming& timing() const { return m_documentLoadTiming; } 115 const DocumentLoadTiming& timing() const { return m_documentLoadTiming; }
116 116
117 ApplicationCacheHost* applicationCacheHost() const { return m_applicationCac heHost.get(); } 117 ApplicationCacheHost* applicationCacheHost() const { return m_applicationCac heHost.get(); }
118 118
119 void clearRedirectChain(); 119 void clearRedirectChain();
120 void appendRedirect(const KURL&); 120 void appendRedirect(const KURL&);
121 121
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 void finishedLoading(double finishTime); 166 void finishedLoading(double finishTime);
167 void cancelLoadAfterXFrameOptionsOrCSPDenied(const ResourceResponse&); 167 void cancelLoadAfterXFrameOptionsOrCSPDenied(const ResourceResponse&);
168 void redirectReceived(Resource*, ResourceRequest&, const ResourceResponse&) final; 168 void redirectReceived(Resource*, ResourceRequest&, const ResourceResponse&) final;
169 void responseReceived(Resource*, const ResourceResponse&, PassOwnPtr<WebData ConsumerHandle>) final; 169 void responseReceived(Resource*, const ResourceResponse&, PassOwnPtr<WebData ConsumerHandle>) final;
170 void dataReceived(Resource*, const char* data, size_t length) final; 170 void dataReceived(Resource*, const char* data, size_t length) final;
171 void processData(const char* data, size_t length); 171 void processData(const char* data, size_t length);
172 void notifyFinished(Resource*) final; 172 void notifyFinished(Resource*) final;
173 String debugName() const override { return "DocumentLoader"; } 173 String debugName() const override { return "DocumentLoader"; }
174 174
175 bool maybeLoadEmpty(); 175 bool maybeLoadEmpty();
176 void loadUnique();
176 177
177 bool isRedirectAfterPost(const ResourceRequest&, const ResourceResponse&); 178 bool isRedirectAfterPost(const ResourceRequest&, const ResourceResponse&);
178 179
179 bool shouldContinueForResponse() const; 180 bool shouldContinueForResponse() const;
180 181
181 Member<LocalFrame> m_frame; 182 Member<LocalFrame> m_frame;
182 Member<ResourceFetcher> m_fetcher; 183 Member<ResourceFetcher> m_fetcher;
183 184
184 Member<RawResource> m_mainResource; 185 Member<RawResource> m_mainResource;
185 186
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 // Used to protect against reentrancy into dataReceived(). 230 // Used to protect against reentrancy into dataReceived().
230 bool m_inDataReceived; 231 bool m_inDataReceived;
231 RefPtr<SharedBuffer> m_dataBuffer; 232 RefPtr<SharedBuffer> m_dataBuffer;
232 }; 233 };
233 234
234 DECLARE_WEAK_IDENTIFIER_MAP(DocumentLoader); 235 DECLARE_WEAK_IDENTIFIER_MAP(DocumentLoader);
235 236
236 } // namespace blink 237 } // namespace blink
237 238
238 #endif // DocumentLoader_h 239 #endif // DocumentLoader_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698