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

Side by Side Diff: chrome/browser/ui/webui/net_internals/net_internals_ui.cc

Issue 13035003: Added a PolicyCertVerifier that uses the trust anchors from the ONC policies. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: addressed comments Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/profiles/profile_io_data.cc ('k') | chrome/chrome_browser_chromeos.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "chrome/browser/ui/webui/net_internals/net_internals_ui.h" 5 #include "chrome/browser/ui/webui/net_internals/net_internals_ui.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <list> 8 #include <list>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 1501 matching lines...) Expand 10 before | Expand all | Expand 10 after
1512 !list->GetString(0, &onc_blob) || 1512 !list->GetString(0, &onc_blob) ||
1513 !list->GetString(1, &passcode)) { 1513 !list->GetString(1, &passcode)) {
1514 NOTREACHED(); 1514 NOTREACHED();
1515 } 1515 }
1516 1516
1517 std::string error; 1517 std::string error;
1518 chromeos::NetworkLibrary* cros_network = 1518 chromeos::NetworkLibrary* cros_network =
1519 chromeos::CrosLibrary::Get()->GetNetworkLibrary(); 1519 chromeos::CrosLibrary::Get()->GetNetworkLibrary();
1520 if (!cros_network->LoadOncNetworks(onc_blob, passcode, 1520 if (!cros_network->LoadOncNetworks(onc_blob, passcode,
1521 chromeos::onc::ONC_SOURCE_USER_IMPORT, 1521 chromeos::onc::ONC_SOURCE_USER_IMPORT,
1522 false)) { // allow web trust from policy 1522 NULL)) {
1523 error = "Errors occurred during the ONC import."; 1523 error = "Errors occurred during the ONC import.";
1524 LOG(ERROR) << error; 1524 LOG(ERROR) << error;
1525 } 1525 }
1526 1526
1527 // Now that we've added the networks, we need to rescan them so they'll be 1527 // Now that we've added the networks, we need to rescan them so they'll be
1528 // available from the menu more immediately. 1528 // available from the menu more immediately.
1529 cros_network->RequestNetworkScan(); 1529 cros_network->RequestNetworkScan();
1530 1530
1531 SendJavascriptCommand("receivedONCFileParse", 1531 SendJavascriptCommand("receivedONCFileParse",
1532 Value::CreateStringValue(error)); 1532 Value::CreateStringValue(error));
(...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after
1938 } 1938 }
1939 1939
1940 NetInternalsUI::NetInternalsUI(content::WebUI* web_ui) 1940 NetInternalsUI::NetInternalsUI(content::WebUI* web_ui)
1941 : WebUIController(web_ui) { 1941 : WebUIController(web_ui) {
1942 web_ui->AddMessageHandler(new NetInternalsMessageHandler()); 1942 web_ui->AddMessageHandler(new NetInternalsMessageHandler());
1943 1943
1944 // Set up the chrome://net-internals/ source. 1944 // Set up the chrome://net-internals/ source.
1945 Profile* profile = Profile::FromWebUI(web_ui); 1945 Profile* profile = Profile::FromWebUI(web_ui);
1946 content::WebUIDataSource::Add(profile, CreateNetInternalsHTMLSource()); 1946 content::WebUIDataSource::Add(profile, CreateNetInternalsHTMLSource());
1947 } 1947 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_io_data.cc ('k') | chrome/chrome_browser_chromeos.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698