Chromium Code Reviews| 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 #if defined(USE_OPENSSL) | 7 #if defined(USE_OPENSSL) |
| 8 #include <openssl/ecdsa.h> | 8 #include <openssl/ecdsa.h> |
| 9 #include <openssl/ssl.h> | 9 #include <openssl/ssl.h> |
| 10 #else // !defined(USE_OPENSSL) | 10 #else // !defined(USE_OPENSSL) |
| (...skipping 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1026 } | 1026 } |
| 1027 | 1027 |
| 1028 if (enable_static_pins_ && result.has_pins) { | 1028 if (enable_static_pins_ && result.has_pins) { |
| 1029 pkp_state->include_subdomains = result.pkp_include_subdomains; | 1029 pkp_state->include_subdomains = result.pkp_include_subdomains; |
| 1030 pkp_state->last_observed = base::GetBuildTime(); | 1030 pkp_state->last_observed = base::GetBuildTime(); |
| 1031 | 1031 |
| 1032 if (result.pinset_id >= arraysize(kPinsets)) | 1032 if (result.pinset_id >= arraysize(kPinsets)) |
| 1033 return false; | 1033 return false; |
| 1034 const Pinset *pinset = &kPinsets[result.pinset_id]; | 1034 const Pinset *pinset = &kPinsets[result.pinset_id]; |
| 1035 | 1035 |
| 1036 if (pinset->report_uri != kNoReportUri) | |
|
agl
2015/08/07 23:10:01
Will need to be kNoReportURI since I changed the c
estark
2015/08/10 05:34:26
Done.
| |
| 1037 pkp_state->report_uri = GURL(pinset->report_uri); | |
| 1038 | |
| 1036 if (pinset->accepted_pins) { | 1039 if (pinset->accepted_pins) { |
| 1037 const char* const* sha1_hash = pinset->accepted_pins; | 1040 const char* const* sha1_hash = pinset->accepted_pins; |
| 1038 while (*sha1_hash) { | 1041 while (*sha1_hash) { |
| 1039 AddHash(*sha1_hash, &pkp_state->spki_hashes); | 1042 AddHash(*sha1_hash, &pkp_state->spki_hashes); |
| 1040 sha1_hash++; | 1043 sha1_hash++; |
| 1041 } | 1044 } |
| 1042 } | 1045 } |
| 1043 if (pinset->rejected_pins) { | 1046 if (pinset->rejected_pins) { |
| 1044 const char* const* sha1_hash = pinset->rejected_pins; | 1047 const char* const* sha1_hash = pinset->rejected_pins; |
| 1045 while (*sha1_hash) { | 1048 while (*sha1_hash) { |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1226 TransportSecurityState::PKPStateIterator::PKPStateIterator( | 1229 TransportSecurityState::PKPStateIterator::PKPStateIterator( |
| 1227 const TransportSecurityState& state) | 1230 const TransportSecurityState& state) |
| 1228 : iterator_(state.enabled_pkp_hosts_.begin()), | 1231 : iterator_(state.enabled_pkp_hosts_.begin()), |
| 1229 end_(state.enabled_pkp_hosts_.end()) { | 1232 end_(state.enabled_pkp_hosts_.end()) { |
| 1230 } | 1233 } |
| 1231 | 1234 |
| 1232 TransportSecurityState::PKPStateIterator::~PKPStateIterator() { | 1235 TransportSecurityState::PKPStateIterator::~PKPStateIterator() { |
| 1233 } | 1236 } |
| 1234 | 1237 |
| 1235 } // namespace | 1238 } // namespace |
| OLD | NEW |