| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/validating_authenticator.h" | 5 #include "remoting/protocol/validating_authenticator.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| 11 #include "base/bind.h" | 11 #include "base/bind.h" |
| 12 #include "base/callback.h" | 12 #include "base/callback.h" |
| 13 #include "base/logging.h" | 13 #include "base/logging.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #include "base/memory/ref_counted.h" | 15 #include "base/memory/ref_counted.h" |
| 16 #include "base/memory/weak_ptr.h" | 16 #include "base/memory/weak_ptr.h" |
| 17 #include "remoting/protocol/authenticator.h" | 17 #include "remoting/protocol/authenticator.h" |
| 18 #include "remoting/protocol/channel_authenticator.h" | 18 #include "remoting/protocol/channel_authenticator.h" |
| 19 #include "third_party/webrtc/libjingle/xmllite/xmlelement.h" | 19 #include "third_party/libjingle_xmpp/xmllite/xmlelement.h" |
| 20 | 20 |
| 21 namespace remoting { | 21 namespace remoting { |
| 22 namespace protocol { | 22 namespace protocol { |
| 23 | 23 |
| 24 ValidatingAuthenticator::ValidatingAuthenticator( | 24 ValidatingAuthenticator::ValidatingAuthenticator( |
| 25 const std::string& remote_jid, | 25 const std::string& remote_jid, |
| 26 const ValidationCallback& validation_callback, | 26 const ValidationCallback& validation_callback, |
| 27 std::unique_ptr<Authenticator> current_authenticator) | 27 std::unique_ptr<Authenticator> current_authenticator) |
| 28 : remote_jid_(remote_jid), | 28 : remote_jid_(remote_jid), |
| 29 validation_callback_(validation_callback), | 29 validation_callback_(validation_callback), |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 126 state_ = current_authenticator_->state(); | 126 state_ = current_authenticator_->state(); |
| 127 if (state_ == REJECTED) { | 127 if (state_ == REJECTED) { |
| 128 rejection_reason_ = current_authenticator_->rejection_reason(); | 128 rejection_reason_ = current_authenticator_->rejection_reason(); |
| 129 } | 129 } |
| 130 | 130 |
| 131 resume_callback.Run(); | 131 resume_callback.Run(); |
| 132 } | 132 } |
| 133 | 133 |
| 134 } // namespace protocol | 134 } // namespace protocol |
| 135 } // namespace remoting | 135 } // namespace remoting |
| OLD | NEW |