OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "remoting/protocol/pairing_registry.h" | 5 #include "remoting/protocol/pairing_registry.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
11 #include "base/base64.h" | 11 #include "base/base64.h" |
12 #include "base/bind.h" | 12 #include "base/bind.h" |
13 #include "base/guid.h" | 13 #include "base/guid.h" |
14 #include "base/json/json_string_value_serializer.h" | 14 #include "base/json/json_string_value_serializer.h" |
15 #include "base/location.h" | 15 #include "base/location.h" |
16 #include "base/macros.h" | 16 #include "base/macros.h" |
17 #include "base/single_thread_task_runner.h" | 17 #include "base/single_thread_task_runner.h" |
18 #include "base/strings/string_number_conversions.h" | 18 #include "base/strings/string_number_conversions.h" |
19 #include "base/thread_task_runner_handle.h" | 19 #include "base/threading/thread_task_runner_handle.h" |
20 #include "base/values.h" | 20 #include "base/values.h" |
21 #include "crypto/random.h" | 21 #include "crypto/random.h" |
22 | 22 |
23 namespace remoting { | 23 namespace remoting { |
24 namespace protocol { | 24 namespace protocol { |
25 | 25 |
26 // How many bytes of random data to use for the shared secret. | 26 // How many bytes of random data to use for the shared secret. |
27 const int kKeySize = 16; | 27 const int kKeySize = 16; |
28 | 28 |
29 const char PairingRegistry::kCreatedTimeKey[] = "createdTime"; | 29 const char PairingRegistry::kCreatedTimeKey[] = "createdTime"; |
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
302 | 302 |
303 void PairingRegistry::ServiceNextRequest() { | 303 void PairingRegistry::ServiceNextRequest() { |
304 if (pending_requests_.empty()) | 304 if (pending_requests_.empty()) |
305 return; | 305 return; |
306 | 306 |
307 PostTask(delegate_task_runner_, FROM_HERE, pending_requests_.front()); | 307 PostTask(delegate_task_runner_, FROM_HERE, pending_requests_.front()); |
308 } | 308 } |
309 | 309 |
310 } // namespace protocol | 310 } // namespace protocol |
311 } // namespace remoting | 311 } // namespace remoting |
OLD | NEW |