summaryrefslogtreecommitdiffstats
path: root/remoting/protocol/pairing_client_authenticator.h
diff options
context:
space:
mode:
authorsergeyu <sergeyu@chromium.org>2016-03-12 01:12:43 -0800
committerCommit bot <commit-bot@chromium.org>2016-03-12 09:13:50 +0000
commit64adc27d798830194401562945398dd396e652db (patch)
treed2ed336be3327744e57bb132bdcb07d4167e6beb /remoting/protocol/pairing_client_authenticator.h
parenta15e4f0ac7ec67afd93957fa56f1ef027ec3775a (diff)
downloadchromium_src-64adc27d798830194401562945398dd396e652db.zip
chromium_src-64adc27d798830194401562945398dd396e652db.tar.gz
chromium_src-64adc27d798830194401562945398dd396e652db.tar.bz2
Use ClientAuthenticationConfig in PairingClientAuthenticator
Moved ClientAuthenticationConfig to a separate file and now it's used in PairingClientAuthenticator. BUG=593123 Review URL: https://codereview.chromium.org/1794433002 Cr-Commit-Position: refs/heads/master@{#380872}
Diffstat (limited to 'remoting/protocol/pairing_client_authenticator.h')
-rw-r--r--remoting/protocol/pairing_client_authenticator.h19
1 files changed, 8 insertions, 11 deletions
diff --git a/remoting/protocol/pairing_client_authenticator.h b/remoting/protocol/pairing_client_authenticator.h
index ad93877..1404e35 100644
--- a/remoting/protocol/pairing_client_authenticator.h
+++ b/remoting/protocol/pairing_client_authenticator.h
@@ -7,6 +7,7 @@
#include "base/macros.h"
#include "base/memory/weak_ptr.h"
+#include "remoting/protocol/client_authentication_config.h"
#include "remoting/protocol/pairing_authenticator_base.h"
namespace remoting {
@@ -15,11 +16,9 @@ namespace protocol {
class PairingClientAuthenticator : public PairingAuthenticatorBase {
public:
PairingClientAuthenticator(
- const std::string& client_id,
- const std::string& paired_secret,
- const CreateBaseAuthenticatorCallback& create_base_authenticator_callback,
- const FetchSecretCallback& fetch_pin_callback,
- const std::string& host_id);
+ const ClientAuthenticationConfig& client_auth_config,
+ const CreateBaseAuthenticatorCallback&
+ create_base_authenticator_callback);
~PairingClientAuthenticator() override;
// Authenticator interface.
@@ -36,13 +35,11 @@ class PairingClientAuthenticator : public PairingAuthenticatorBase {
const base::Closure& resume_callback,
const std::string& pin);
- // Protocol state.
- bool sent_client_id_ = false;
- std::string client_id_;
- std::string paired_secret_;
+ ClientAuthenticationConfig client_auth_config_;
CreateBaseAuthenticatorCallback create_base_authenticator_callback_;
- FetchSecretCallback fetch_pin_callback_;
- std::string host_id_;
+
+ // 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.