| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "ios/chrome/browser/component_updater/ios_component_updater_configurato
r.h" | 5 #include "ios/chrome/browser/component_updater/ios_component_updater_configurato
r.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/threading/sequenced_worker_pool.h" | 10 #include "base/threading/sequenced_worker_pool.h" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 const override; | 48 const override; |
| 49 | 49 |
| 50 private: | 50 private: |
| 51 friend class base::RefCountedThreadSafe<IOSConfigurator>; | 51 friend class base::RefCountedThreadSafe<IOSConfigurator>; |
| 52 | 52 |
| 53 ConfiguratorImpl configurator_impl_; | 53 ConfiguratorImpl configurator_impl_; |
| 54 | 54 |
| 55 ~IOSConfigurator() override {} | 55 ~IOSConfigurator() override {} |
| 56 }; | 56 }; |
| 57 | 57 |
| 58 // Allows the component updater to use non-encrypted communication with the |
| 59 // update backend. The security of the update checks is enforced using |
| 60 // a custom message signing protocol and it does not depend on using HTTPS. |
| 58 IOSConfigurator::IOSConfigurator( | 61 IOSConfigurator::IOSConfigurator( |
| 59 const base::CommandLine* cmdline, | 62 const base::CommandLine* cmdline, |
| 60 net::URLRequestContextGetter* url_request_getter) | 63 net::URLRequestContextGetter* url_request_getter) |
| 61 : configurator_impl_(cmdline, url_request_getter) {} | 64 : configurator_impl_(cmdline, url_request_getter, false) {} |
| 62 | 65 |
| 63 int IOSConfigurator::InitialDelay() const { | 66 int IOSConfigurator::InitialDelay() const { |
| 64 return configurator_impl_.InitialDelay(); | 67 return configurator_impl_.InitialDelay(); |
| 65 } | 68 } |
| 66 | 69 |
| 67 int IOSConfigurator::NextCheckDelay() const { | 70 int IOSConfigurator::NextCheckDelay() const { |
| 68 return configurator_impl_.NextCheckDelay(); | 71 return configurator_impl_.NextCheckDelay(); |
| 69 } | 72 } |
| 70 | 73 |
| 71 int IOSConfigurator::StepDelay() const { | 74 int IOSConfigurator::StepDelay() const { |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 143 | 146 |
| 144 } // namespace | 147 } // namespace |
| 145 | 148 |
| 146 scoped_refptr<update_client::Configurator> MakeIOSComponentUpdaterConfigurator( | 149 scoped_refptr<update_client::Configurator> MakeIOSComponentUpdaterConfigurator( |
| 147 const base::CommandLine* cmdline, | 150 const base::CommandLine* cmdline, |
| 148 net::URLRequestContextGetter* context_getter) { | 151 net::URLRequestContextGetter* context_getter) { |
| 149 return new IOSConfigurator(cmdline, context_getter); | 152 return new IOSConfigurator(cmdline, context_getter); |
| 150 } | 153 } |
| 151 | 154 |
| 152 } // namespace component_updater | 155 } // namespace component_updater |
| OLD | NEW |