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/negotiating_host_authenticator.h" | 5 #include "remoting/protocol/negotiating_host_authenticator.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <sstream> | 8 #include <sstream> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
11 #include "base/callback.h" | 11 #include "base/callback.h" |
12 #include "base/logging.h" | 12 #include "base/logging.h" |
13 #include "base/strings/string_split.h" | 13 #include "base/strings/string_split.h" |
14 #include "remoting/base/rsa_key_pair.h" | 14 #include "remoting/base/rsa_key_pair.h" |
15 #include "remoting/protocol/channel_authenticator.h" | 15 #include "remoting/protocol/channel_authenticator.h" |
16 #include "remoting/protocol/pairing_host_authenticator.h" | 16 #include "remoting/protocol/pairing_host_authenticator.h" |
17 #include "remoting/protocol/pairing_registry.h" | 17 #include "remoting/protocol/pairing_registry.h" |
18 #include "remoting/protocol/token_validator.h" | 18 #include "remoting/protocol/token_validator.h" |
19 #include "remoting/protocol/v2_authenticator.h" | 19 #include "remoting/protocol/v2_authenticator.h" |
20 #include "third_party/libjingle/source/talk/xmllite/xmlelement.h" | 20 #include "third_party/webrtc/libjingle/xmllite/xmlelement.h" |
21 | 21 |
22 namespace remoting { | 22 namespace remoting { |
23 namespace protocol { | 23 namespace protocol { |
24 | 24 |
25 NegotiatingHostAuthenticator::NegotiatingHostAuthenticator( | 25 NegotiatingHostAuthenticator::NegotiatingHostAuthenticator( |
26 const std::string& local_cert, | 26 const std::string& local_cert, |
27 scoped_refptr<RsaKeyPair> key_pair) | 27 scoped_refptr<RsaKeyPair> key_pair) |
28 : NegotiatingAuthenticatorBase(WAITING_MESSAGE), | 28 : NegotiatingAuthenticatorBase(WAITING_MESSAGE), |
29 local_cert_(local_cert), | 29 local_cert_(local_cert), |
30 local_key_pair_(key_pair) { | 30 local_key_pair_(key_pair) { |
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 current_method_.type() == AuthenticationMethod::SPAKE2_PAIR); | 181 current_method_.type() == AuthenticationMethod::SPAKE2_PAIR); |
182 current_authenticator_ = V2Authenticator::CreateForHost( | 182 current_authenticator_ = V2Authenticator::CreateForHost( |
183 local_cert_, local_key_pair_, shared_secret_hash_, | 183 local_cert_, local_key_pair_, shared_secret_hash_, |
184 preferred_initial_state); | 184 preferred_initial_state); |
185 } | 185 } |
186 resume_callback.Run(); | 186 resume_callback.Run(); |
187 } | 187 } |
188 | 188 |
189 } // namespace protocol | 189 } // namespace protocol |
190 } // namespace remoting | 190 } // namespace remoting |
OLD | NEW |