Index: remoting/protocol/pairing_client_authenticator.h |
diff --git a/remoting/protocol/pairing_client_authenticator.h b/remoting/protocol/pairing_client_authenticator.h |
index 1404e35ed87dc5c784107ebcc774c38b054e4c7e..fafd2d728df71a1fd1665b14f323abce4ebb4cb7 100644 |
--- a/remoting/protocol/pairing_client_authenticator.h |
+++ b/remoting/protocol/pairing_client_authenticator.h |
@@ -21,6 +21,16 @@ class PairingClientAuthenticator : public PairingAuthenticatorBase { |
create_base_authenticator_callback); |
~PairingClientAuthenticator() override; |
+ // Start() or StartPaired() must be called after the authenticator is created. |
+ // Start() handles both cases when pairing exists and when it doesn't. |
+ // StartPaired() can only be used when pairing exists (i.e. client_id and |
+ // pairing_secret are set in the |client_auth_config|). It is used to |
+ // initialize the authenticator synchronously in |
+ // NegotiatingClientAuthentitcator, while Start() may be executed |
+ // asynchronously to fetch the PIN. |
+ void Start(State initial_state, const base::Closure& resume_callback); |
+ void StartPaired(State initial_state); |
+ |
// Authenticator interface. |
State state() const override; |
@@ -29,7 +39,6 @@ class PairingClientAuthenticator : public PairingAuthenticatorBase { |
void CreateSpakeAuthenticatorWithPin( |
State initial_state, |
const base::Closure& resume_callback) override; |
- void AddPairingElements(buzz::XmlElement* message) override; |
void OnPinFetched(State initial_state, |
const base::Closure& resume_callback, |
@@ -38,9 +47,6 @@ class PairingClientAuthenticator : public PairingAuthenticatorBase { |
ClientAuthenticationConfig client_auth_config_; |
CreateBaseAuthenticatorCallback create_base_authenticator_callback_; |
- // Set to true after client_id is sent to the host. |
- bool sent_client_id_ = false; |
- |
// Set to true if a PIN-based authenticator has been requested but has not |
// yet been set. |
bool waiting_for_pin_ = false; |