Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4134)

Unified Diff: chrome/browser/ui/webui/net_internals/net_internals_ui.cc

Issue 9415040: Refactor TransportSecurityState. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/transport_security_persister_unittest.cc ('k') | chrome/chrome_tests.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/net_internals/net_internals_ui.cc
===================================================================
--- chrome/browser/ui/webui/net_internals/net_internals_ui.cc (revision 134551)
+++ chrome/browser/ui/webui/net_internals/net_internals_ui.cc (working copy)
@@ -1040,22 +1040,21 @@
result->SetString("error", "no TransportSecurityState active");
} else {
net::TransportSecurityState::DomainState state;
- const bool found = transport_security_state->HasMetadata(
- &state, domain, true);
+ const bool found = transport_security_state->GetDomainState(
+ domain, true, &state);
result->SetBoolean("result", found);
if (found) {
- result->SetInteger("mode", static_cast<int>(state.mode));
+ result->SetInteger("mode", static_cast<int>(state.upgrade_mode));
result->SetBoolean("subdomains", state.include_subdomains);
- result->SetBoolean("preloaded", state.preloaded);
result->SetString("domain", state.domain);
- result->SetDouble("expiry", state.expiry.ToDoubleT());
+ result->SetDouble("expiry", state.upgrade_expiry.ToDoubleT());
result->SetDouble("dynamic_spki_hashes_expiry",
state.dynamic_spki_hashes_expiry.ToDoubleT());
std::string hashes;
- SPKIHashesToString(state.preloaded_spki_hashes, &hashes);
- result->SetString("preloaded_spki_hashes", hashes);
+ SPKIHashesToString(state.static_spki_hashes, &hashes);
+ result->SetString("static_spki_hashes", hashes);
hashes.clear();
SPKIHashesToString(state.dynamic_spki_hashes, &hashes);
@@ -1088,7 +1087,7 @@
return;
net::TransportSecurityState::DomainState state;
- state.expiry = state.created + base::TimeDelta::FromDays(1000);
+ state.upgrade_expiry = state.created + base::TimeDelta::FromDays(1000);
state.include_subdomains = include_subdomains;
if (!hashes_str.empty()) {
std::vector<std::string> type_and_b64s;
« no previous file with comments | « chrome/browser/transport_security_persister_unittest.cc ('k') | chrome/chrome_tests.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698