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

Side by Side Diff: chrome/browser/renderer_host/resource_request_details.h

Issue 42314: SSLPolicy fix: Step 9. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/ssl/ssl_host_state.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // The ResourceRequestDetails object contains additional details about a 5 // The ResourceRequestDetails object contains additional details about a
6 // resource request. It copies many of the publicly accessible member variables 6 // resource request. It copies many of the publicly accessible member variables
7 // of URLRequest, but exists on the UI thread. 7 // of URLRequest, but exists on the UI thread.
8 8
9 #ifndef CHROME_BROWSER_RENDERER_HOST_RESOURCE_REQUEST_DETAILS_H_ 9 #ifndef CHROME_BROWSER_RENDERER_HOST_RESOURCE_REQUEST_DETAILS_H_
10 #define CHROME_BROWSER_RENDERER_HOST_RESOURCE_REQUEST_DETAILS_H_ 10 #define CHROME_BROWSER_RENDERER_HOST_RESOURCE_REQUEST_DETAILS_H_
(...skipping 26 matching lines...) Expand all
37 origin_pid_(request->origin_pid()), 37 origin_pid_(request->origin_pid()),
38 status_(request->status()), 38 status_(request->status()),
39 ssl_cert_id_(cert_id), 39 ssl_cert_id_(cert_id),
40 ssl_cert_status_(request->ssl_info().cert_status) { 40 ssl_cert_status_(request->ssl_info().cert_status) {
41 const ResourceDispatcherHost::ExtraRequestInfo* info = 41 const ResourceDispatcherHost::ExtraRequestInfo* info =
42 ResourceDispatcherHost::ExtraInfoForRequest(request); 42 ResourceDispatcherHost::ExtraInfoForRequest(request);
43 DCHECK(info); 43 DCHECK(info);
44 resource_type_ = info->resource_type; 44 resource_type_ = info->resource_type;
45 frame_origin_ = info->frame_origin; 45 frame_origin_ = info->frame_origin;
46 main_frame_origin_ = info->main_frame_origin; 46 main_frame_origin_ = info->main_frame_origin;
47 filter_policy_ = info->filter_policy;
47 } 48 }
48 49
49 ~ResourceRequestDetails() { } 50 ~ResourceRequestDetails() { }
50 51
51 const GURL& url() const { return url_; } 52 const GURL& url() const { return url_; }
52 const GURL& original_url() const { return original_url_; } 53 const GURL& original_url() const { return original_url_; }
53 const std::string& method() const { return method_; } 54 const std::string& method() const { return method_; }
54 const std::string& referrer() const { return referrer_; } 55 const std::string& referrer() const { return referrer_; }
55 const std::string& frame_origin() const { return frame_origin_; } 56 const std::string& frame_origin() const { return frame_origin_; }
56 const std::string& main_frame_origin() const { return main_frame_origin_; } 57 const std::string& main_frame_origin() const { return main_frame_origin_; }
57 bool has_upload() const { return has_upload_; } 58 bool has_upload() const { return has_upload_; }
58 int load_flags() const { return load_flags_; } 59 int load_flags() const { return load_flags_; }
59 int origin_pid() const { return origin_pid_; } 60 int origin_pid() const { return origin_pid_; }
60 const URLRequestStatus& status() const { return status_; } 61 const URLRequestStatus& status() const { return status_; }
61 int ssl_cert_id() const { return ssl_cert_id_; } 62 int ssl_cert_id() const { return ssl_cert_id_; }
62 int ssl_cert_status() const { return ssl_cert_status_; } 63 int ssl_cert_status() const { return ssl_cert_status_; }
63 ResourceType::Type resource_type() const { return resource_type_; } 64 ResourceType::Type resource_type() const { return resource_type_; }
65 FilterPolicy::Type filter_policy() const { return filter_policy_; }
64 66
65 private: 67 private:
66 GURL url_; 68 GURL url_;
67 GURL original_url_; 69 GURL original_url_;
68 std::string method_; 70 std::string method_;
69 std::string referrer_; 71 std::string referrer_;
70 std::string frame_origin_; 72 std::string frame_origin_;
71 std::string main_frame_origin_; 73 std::string main_frame_origin_;
72 bool has_upload_; 74 bool has_upload_;
73 int load_flags_; 75 int load_flags_;
74 int origin_pid_; 76 int origin_pid_;
75 URLRequestStatus status_; 77 URLRequestStatus status_;
76 int ssl_cert_id_; 78 int ssl_cert_id_;
77 int ssl_cert_status_; 79 int ssl_cert_status_;
78 ResourceType::Type resource_type_; 80 ResourceType::Type resource_type_;
81 FilterPolicy::Type filter_policy_;
79 82
80 DISALLOW_COPY_AND_ASSIGN(ResourceRequestDetails); 83 DISALLOW_COPY_AND_ASSIGN(ResourceRequestDetails);
81 }; 84 };
82 85
83 // Details about a redirection of a resource request. 86 // Details about a redirection of a resource request.
84 class ResourceRedirectDetails : public ResourceRequestDetails { 87 class ResourceRedirectDetails : public ResourceRequestDetails {
85 public: 88 public:
86 ResourceRedirectDetails(const URLRequest* request, 89 ResourceRedirectDetails(const URLRequest* request,
87 int cert_id, 90 int cert_id,
88 const GURL& new_url) 91 const GURL& new_url)
89 : ResourceRequestDetails(request, cert_id), 92 : ResourceRequestDetails(request, cert_id),
90 new_url_(new_url) { } 93 new_url_(new_url) { }
91 94
92 // The URL to which we are being redirected. 95 // The URL to which we are being redirected.
93 const GURL& new_url() const { return new_url_; } 96 const GURL& new_url() const { return new_url_; }
94 97
95 private: 98 private:
96 GURL new_url_; 99 GURL new_url_;
97 }; 100 };
98 101
99 #endif // CHROME_BROWSER_RENDERER_HOST_RESOURCE_REQUEST_DETAILS_H_ 102 #endif // CHROME_BROWSER_RENDERER_HOST_RESOURCE_REQUEST_DETAILS_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ssl/ssl_host_state.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698