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