// Copyright 2012 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef REMOTING_PROTOCOL_AUTHENTICATOR_H_ #define REMOTING_PROTOCOL_AUTHENTICATOR_H_ #include <memory> #include <string> #include "base/functional/callback.h" #include "remoting/protocol/credentials_type.h" namespace jingle_xmpp { class XmlElement; } // namespace jingle_xmpp namespace remoting::protocol { class Authenticator; class ChannelAuthenticator; // Authenticator is an abstract interface for authentication protocol // implementations. Different implementations of this interface may be used on // each side of the connection depending of type of the auth protocol. Client // and host will repeatedly call their Authenticators and deliver the messages // they generate, until successful authentication is reported. // // Authenticator may exchange multiple messages before session is authenticated. // Each message sent/received by an Authenticator is delivered either in a // session description inside session-initiate and session-accept messages or in // a session-info message. Session-info messages are used only if authenticators // need to exchange more than one message. class Authenticator { … }; // Factory for Authenticator instances. class AuthenticatorFactory { … }; } // namespace remoting::protocol #endif // REMOTING_PROTOCOL_AUTHENTICATOR_H_