OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 815 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
826 GetFrame()->GetDocument()->GetSecurityOrigin()->Protocol())) { | 826 GetFrame()->GetDocument()->GetSecurityOrigin()->Protocol())) { |
827 Deprecation::CountDeprecation( | 827 Deprecation::CountDeprecation( |
828 GetFrame()->GetDocument(), | 828 GetFrame()->GetDocument(), |
829 UseCounter::kLegacyProtocolEmbeddedAsSubresource); | 829 UseCounter::kLegacyProtocolEmbeddedAsSubresource); |
830 | 830 |
831 // TODO(mkwst): Enabled by default in M59. Drop the runtime-enabled check | 831 // TODO(mkwst): Enabled by default in M59. Drop the runtime-enabled check |
832 // in M60: https://www.chromestatus.com/feature/5709390967472128 | 832 // in M60: https://www.chromestatus.com/feature/5709390967472128 |
833 if (RuntimeEnabledFeatures::blockLegacySubresourcesEnabled()) | 833 if (RuntimeEnabledFeatures::blockLegacySubresourcesEnabled()) |
834 return ResourceRequestBlockedReason::kOrigin; | 834 return ResourceRequestBlockedReason::kOrigin; |
835 } | 835 } |
836 if (!url.User().IsEmpty() || !url.Pass().IsEmpty()) { | 836 |
| 837 if ((!url.User().IsEmpty() || !url.Pass().IsEmpty()) && |
| 838 resource_request.GetRequestContext() != |
| 839 WebURLRequest::kRequestContextXMLHttpRequest) { |
837 Deprecation::CountDeprecation( | 840 Deprecation::CountDeprecation( |
838 GetFrame()->GetDocument(), | 841 GetFrame()->GetDocument(), |
839 UseCounter::kRequestedSubresourceWithEmbeddedCredentials); | 842 UseCounter::kRequestedSubresourceWithEmbeddedCredentials); |
840 // TODO(mkwst): Remove the runtime-enabled check in M59: | 843 // TODO(mkwst): Remove the runtime-enabled check in M59: |
841 // https://www.chromestatus.com/feature/5669008342777856 | 844 // https://www.chromestatus.com/feature/5669008342777856 |
842 if (RuntimeEnabledFeatures::blockCredentialedSubresourcesEnabled()) | 845 if (RuntimeEnabledFeatures::blockCredentialedSubresourcesEnabled()) |
843 return ResourceRequestBlockedReason::kOrigin; | 846 return ResourceRequestBlockedReason::kOrigin; |
844 } | 847 } |
845 } | 848 } |
846 | 849 |
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1087 return GetFrame()->FrameScheduler()->LoadingTaskRunner(); | 1090 return GetFrame()->FrameScheduler()->LoadingTaskRunner(); |
1088 } | 1091 } |
1089 | 1092 |
1090 DEFINE_TRACE(FrameFetchContext) { | 1093 DEFINE_TRACE(FrameFetchContext) { |
1091 visitor->Trace(document_); | 1094 visitor->Trace(document_); |
1092 visitor->Trace(document_loader_); | 1095 visitor->Trace(document_loader_); |
1093 FetchContext::Trace(visitor); | 1096 FetchContext::Trace(visitor); |
1094 } | 1097 } |
1095 | 1098 |
1096 } // namespace blink | 1099 } // namespace blink |
OLD | NEW |