| 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 #include "net/http/transport_security_state.h" | 5 #include "net/http/transport_security_state.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 696 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 707 if (!base::JSONWriter::Write(report, out_serialized_report)) | 707 if (!base::JSONWriter::Write(report, out_serialized_report)) |
| 708 return false; | 708 return false; |
| 709 return true; | 709 return true; |
| 710 } | 710 } |
| 711 | 711 |
| 712 } // namespace | 712 } // namespace |
| 713 | 713 |
| 714 TransportSecurityState::TransportSecurityState() | 714 TransportSecurityState::TransportSecurityState() |
| 715 : enable_static_pins_(true), | 715 : enable_static_pins_(true), |
| 716 enable_static_expect_ct_(true), | 716 enable_static_expect_ct_(true), |
| 717 enable_static_expect_staple_(false), | 717 enable_static_expect_staple_(true), |
| 718 enable_pkp_bypass_for_local_trust_anchors_(true), | 718 enable_pkp_bypass_for_local_trust_anchors_(true), |
| 719 sent_reports_cache_(kMaxHPKPReportCacheEntries) { | 719 sent_reports_cache_(kMaxHPKPReportCacheEntries) { |
| 720 // Static pinning is only enabled for official builds to make sure that | 720 // Static pinning is only enabled for official builds to make sure that |
| 721 // others don't end up with pins that cannot be easily updated. | 721 // others don't end up with pins that cannot be easily updated. |
| 722 #if !defined(OFFICIAL_BUILD) || defined(OS_ANDROID) || defined(OS_IOS) | 722 #if !defined(OFFICIAL_BUILD) || defined(OS_ANDROID) || defined(OS_IOS) |
| 723 enable_static_pins_ = false; | 723 enable_static_pins_ = false; |
| 724 enable_static_expect_ct_ = false; | 724 enable_static_expect_ct_ = false; |
| 725 #endif | 725 #endif |
| 726 DCHECK(CalledOnValidThread()); | 726 DCHECK(CalledOnValidThread()); |
| 727 } | 727 } |
| (...skipping 894 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1622 TransportSecurityState::PKPStateIterator::PKPStateIterator( | 1622 TransportSecurityState::PKPStateIterator::PKPStateIterator( |
| 1623 const TransportSecurityState& state) | 1623 const TransportSecurityState& state) |
| 1624 : iterator_(state.enabled_pkp_hosts_.begin()), | 1624 : iterator_(state.enabled_pkp_hosts_.begin()), |
| 1625 end_(state.enabled_pkp_hosts_.end()) { | 1625 end_(state.enabled_pkp_hosts_.end()) { |
| 1626 } | 1626 } |
| 1627 | 1627 |
| 1628 TransportSecurityState::PKPStateIterator::~PKPStateIterator() { | 1628 TransportSecurityState::PKPStateIterator::~PKPStateIterator() { |
| 1629 } | 1629 } |
| 1630 | 1630 |
| 1631 } // namespace | 1631 } // namespace |
| OLD | NEW |