| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef REMOTING_PROTOCOL_AUTHENTICATOR_H_ | 5 #ifndef REMOTING_PROTOCOL_AUTHENTICATOR_H_ |
| 6 #define REMOTING_PROTOCOL_AUTHENTICATOR_H_ | 6 #define REMOTING_PROTOCOL_AUTHENTICATOR_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 // Called when session-initiate stanza is received to create | 127 // Called when session-initiate stanza is received to create |
| 128 // authenticator for the new session. |first_message| specifies | 128 // authenticator for the new session. |first_message| specifies |
| 129 // authentication part of the session-initiate stanza so that | 129 // authentication part of the session-initiate stanza so that |
| 130 // appropriate type of Authenticator can be chosen for the session | 130 // appropriate type of Authenticator can be chosen for the session |
| 131 // (useful when multiple authenticators is supported). Returns nullptr | 131 // (useful when multiple authenticators is supported). Returns nullptr |
| 132 // if the |first_message| is invalid and the session should be | 132 // if the |first_message| is invalid and the session should be |
| 133 // rejected. ProcessMessage() should be called with |first_message| | 133 // rejected. ProcessMessage() should be called with |first_message| |
| 134 // for the result of this method. | 134 // for the result of this method. |
| 135 virtual scoped_ptr<Authenticator> CreateAuthenticator( | 135 virtual scoped_ptr<Authenticator> CreateAuthenticator( |
| 136 const std::string& local_jid, | 136 const std::string& local_jid, |
| 137 const std::string& remote_jid, | 137 const std::string& remote_jid) = 0; |
| 138 const buzz::XmlElement* first_message) = 0; | |
| 139 }; | 138 }; |
| 140 | 139 |
| 141 } // namespace protocol | 140 } // namespace protocol |
| 142 } // namespace remoting | 141 } // namespace remoting |
| 143 | 142 |
| 144 #endif // REMOTING_PROTOCOL_AUTHENTICATOR_H_ | 143 #endif // REMOTING_PROTOCOL_AUTHENTICATOR_H_ |
| OLD | NEW |