OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef NET_SSL_SSL_PLATFORM_KEY_TASK_RUNNER_H_ |
| 6 #define NET_SSL_SSL_PLATFORM_KEY_TASK_RUNNER_H_ |
| 7 |
| 8 #include "base/threading/sequenced_worker_pool.h" |
| 9 |
| 10 namespace net { |
| 11 |
| 12 // Serialize all the private key operations on a single background |
| 13 // thread to avoid problems with buggy smartcards. |
| 14 class SSLPlatformKeyTaskRunner { |
| 15 public: |
| 16 SSLPlatformKeyTaskRunner(); |
| 17 ~SSLPlatformKeyTaskRunner(); |
| 18 |
| 19 scoped_refptr<base::SequencedTaskRunner> task_runner(); |
| 20 |
| 21 private: |
| 22 scoped_refptr<base::SequencedWorkerPool> worker_pool_; |
| 23 scoped_refptr<base::SequencedTaskRunner> task_runner_; |
| 24 |
| 25 DISALLOW_COPY_AND_ASSIGN(SSLPlatformKeyTaskRunner); |
| 26 }; |
| 27 |
| 28 scoped_refptr<base::SequencedTaskRunner> GetSSLPlatformKeyTaskRunner(); |
| 29 |
| 30 } // namespace net |
| 31 |
| 32 #endif // NET_SSL_SSL_PLATFORM_KEY_TASK_RUNNER_H_ |
OLD | NEW |