| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef NET_URL_REQUEST_URL_REQUEST_H_ | 5 #ifndef NET_URL_REQUEST_URL_REQUEST_H_ |
| 6 #define NET_URL_REQUEST_URL_REQUEST_H_ | 6 #define NET_URL_REQUEST_URL_REQUEST_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 // stripped down to an origin rather than a full URL). Same-origin | 98 // stripped down to an origin rather than a full URL). Same-origin |
| 99 // requests will send the full referrer. | 99 // requests will send the full referrer. |
| 100 REDUCE_REFERRER_GRANULARITY_ON_TRANSITION_CROSS_ORIGIN, | 100 REDUCE_REFERRER_GRANULARITY_ON_TRANSITION_CROSS_ORIGIN, |
| 101 // Strip the referrer down to an origin upon cross-origin navigation. | 101 // Strip the referrer down to an origin upon cross-origin navigation. |
| 102 ORIGIN_ONLY_ON_TRANSITION_CROSS_ORIGIN, | 102 ORIGIN_ONLY_ON_TRANSITION_CROSS_ORIGIN, |
| 103 // Never change the referrer. | 103 // Never change the referrer. |
| 104 NEVER_CLEAR_REFERRER, | 104 NEVER_CLEAR_REFERRER, |
| 105 // Strip the referrer down to the origin regardless of the redirect | 105 // Strip the referrer down to the origin regardless of the redirect |
| 106 // location. | 106 // location. |
| 107 ORIGIN, | 107 ORIGIN, |
| 108 // Clear the referrer on cross-origin redirect locations. |
| 109 CLEAR_REFERRER_ON_TRANSITION_CROSS_ORIGIN, |
| 110 // Strip the referrer down to the origin, but clear it entirely if the |
| 111 // protocol changes from HTTPS to HTTP. |
| 112 ORIGIN_CLEAR_ON_TRANSITION_FROM_SECURE_TO_INSECURE, |
| 108 // Always clear the referrer regardless of the redirect location. | 113 // Always clear the referrer regardless of the redirect location. |
| 109 NO_REFERRER, | 114 NO_REFERRER, |
| 110 MAX_REFERRER_POLICY | 115 MAX_REFERRER_POLICY |
| 111 }; | 116 }; |
| 112 | 117 |
| 113 // First-party URL redirect policy: During server redirects, the first-party | 118 // First-party URL redirect policy: During server redirects, the first-party |
| 114 // URL for cookies normally doesn't change. However, if the request is a | 119 // URL for cookies normally doesn't change. However, if the request is a |
| 115 // top-level first-party request, the first-party URL should be updated to the | 120 // top-level first-party request, the first-party URL should be updated to the |
| 116 // URL on every redirect. | 121 // URL on every redirect. |
| 117 enum FirstPartyURLPolicy { | 122 enum FirstPartyURLPolicy { |
| (...skipping 744 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 862 const NetworkTrafficAnnotationTag traffic_annotation_; | 867 const NetworkTrafficAnnotationTag traffic_annotation_; |
| 863 | 868 |
| 864 THREAD_CHECKER(thread_checker_); | 869 THREAD_CHECKER(thread_checker_); |
| 865 | 870 |
| 866 DISALLOW_COPY_AND_ASSIGN(URLRequest); | 871 DISALLOW_COPY_AND_ASSIGN(URLRequest); |
| 867 }; | 872 }; |
| 868 | 873 |
| 869 } // namespace net | 874 } // namespace net |
| 870 | 875 |
| 871 #endif // NET_URL_REQUEST_URL_REQUEST_H_ | 876 #endif // NET_URL_REQUEST_URL_REQUEST_H_ |
| OLD | NEW |