| 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 "chrome/browser/net/crl_set_fetcher.h" | 5 #include "chrome/browser/net/crl_set_fetcher.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/files/file_util.h" | 8 #include "base/files/file_util.h" |
| 9 #include "base/numerics/safe_conversions.h" | 9 #include "base/numerics/safe_conversions.h" |
| 10 #include "base/rand_util.h" | 10 #include "base/rand_util.h" |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 | 137 |
| 138 void CRLSetFetcher::RegisterComponent(uint32_t sequence_of_loaded_crl) { | 138 void CRLSetFetcher::RegisterComponent(uint32_t sequence_of_loaded_crl) { |
| 139 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 139 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 140 | 140 |
| 141 update_client::CrxComponent component; | 141 update_client::CrxComponent component; |
| 142 component.pk_hash.assign(kPublicKeySHA256, | 142 component.pk_hash.assign(kPublicKeySHA256, |
| 143 kPublicKeySHA256 + sizeof(kPublicKeySHA256)); | 143 kPublicKeySHA256 + sizeof(kPublicKeySHA256)); |
| 144 component.installer = this; | 144 component.installer = this; |
| 145 component.name = "CRLSet"; | 145 component.name = "CRLSet"; |
| 146 component.version = Version(base::UintToString(sequence_of_loaded_crl)); | 146 component.version = Version(base::UintToString(sequence_of_loaded_crl)); |
| 147 component.allow_background_download = false; | 147 component.allows_background_download = false; |
| 148 component.requires_network_encryption = false; |
| 148 if (!component.version.IsValid()) { | 149 if (!component.version.IsValid()) { |
| 149 NOTREACHED(); | 150 NOTREACHED(); |
| 150 component.version = Version("0"); | 151 component.version = Version("0"); |
| 151 } | 152 } |
| 152 | 153 |
| 153 if (!cus_->RegisterComponent(component)) | 154 if (!cus_->RegisterComponent(component)) |
| 154 NOTREACHED() << "RegisterComponent returned error"; | 155 NOTREACHED() << "RegisterComponent returned error"; |
| 155 } | 156 } |
| 156 | 157 |
| 157 void CRLSetFetcher::DoDeleteFromDisk() { | 158 void CRLSetFetcher::DoDeleteFromDisk() { |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 236 bool CRLSetFetcher::GetInstalledFile( | 237 bool CRLSetFetcher::GetInstalledFile( |
| 237 const std::string& file, base::FilePath* installed_file) { | 238 const std::string& file, base::FilePath* installed_file) { |
| 238 return false; | 239 return false; |
| 239 } | 240 } |
| 240 | 241 |
| 241 bool CRLSetFetcher::Uninstall() { | 242 bool CRLSetFetcher::Uninstall() { |
| 242 return false; | 243 return false; |
| 243 } | 244 } |
| 244 | 245 |
| 245 CRLSetFetcher::~CRLSetFetcher() {} | 246 CRLSetFetcher::~CRLSetFetcher() {} |
| OLD | NEW |