Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1204)

Side by Side Diff: remoting/protocol/third_party_authenticator_base.h

Issue 667123002: Standardize usage of virtual/override/final in remoting/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_THIRD_PARTY_AUTHENTICATOR_BASE_H_ 5 #ifndef REMOTING_PROTOCOL_THIRD_PARTY_AUTHENTICATOR_BASE_H_
6 #define REMOTING_PROTOCOL_THIRD_PARTY_AUTHENTICATOR_BASE_H_ 6 #define REMOTING_PROTOCOL_THIRD_PARTY_AUTHENTICATOR_BASE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 14 matching lines...) Expand all
25 // authentication of both client and host. 25 // authentication of both client and host.
26 // When third party authentication is being used, the client must request both a 26 // When third party authentication is being used, the client must request both a
27 // token and a shared secret from a third-party server (which may require the 27 // token and a shared secret from a third-party server (which may require the
28 // user to authenticate themselves). The client then sends only the token to the 28 // user to authenticate themselves). The client then sends only the token to the
29 // host. The host signs the token, then contacts the third-party server to 29 // host. The host signs the token, then contacts the third-party server to
30 // exchange the token for the shared secret. Once both client and host have the 30 // exchange the token for the shared secret. Once both client and host have the
31 // shared secret, they use an underlying |V2Authenticator| (SPAKE2) to negotiate 31 // shared secret, they use an underlying |V2Authenticator| (SPAKE2) to negotiate
32 // an authentication key, which is used to establish the connection. 32 // an authentication key, which is used to establish the connection.
33 class ThirdPartyAuthenticatorBase : public Authenticator { 33 class ThirdPartyAuthenticatorBase : public Authenticator {
34 public: 34 public:
35 virtual ~ThirdPartyAuthenticatorBase(); 35 ~ThirdPartyAuthenticatorBase() override;
36 36
37 // Authenticator interface. 37 // Authenticator interface.
38 virtual State state() const override; 38 State state() const override;
39 virtual bool started() const override; 39 bool started() const override;
40 virtual RejectionReason rejection_reason() const override; 40 RejectionReason rejection_reason() const override;
41 virtual void ProcessMessage(const buzz::XmlElement* message, 41 void ProcessMessage(const buzz::XmlElement* message,
42 const base::Closure& resume_callback) override; 42 const base::Closure& resume_callback) override;
43 virtual scoped_ptr<buzz::XmlElement> GetNextMessage() override; 43 scoped_ptr<buzz::XmlElement> GetNextMessage() override;
44 virtual scoped_ptr<ChannelAuthenticator> 44 scoped_ptr<ChannelAuthenticator> CreateChannelAuthenticator() const override;
45 CreateChannelAuthenticator() const override;
46 45
47 protected: 46 protected:
48 // XML tag names for third party authentication fields. 47 // XML tag names for third party authentication fields.
49 static const buzz::StaticQName kTokenUrlTag; 48 static const buzz::StaticQName kTokenUrlTag;
50 static const buzz::StaticQName kTokenScopeTag; 49 static const buzz::StaticQName kTokenScopeTag;
51 static const buzz::StaticQName kTokenTag; 50 static const buzz::StaticQName kTokenTag;
52 51
53 explicit ThirdPartyAuthenticatorBase(State initial_state); 52 explicit ThirdPartyAuthenticatorBase(State initial_state);
54 53
55 // Gives the message to the underlying authenticator for processing. 54 // Gives the message to the underlying authenticator for processing.
(...skipping 15 matching lines...) Expand all
71 RejectionReason rejection_reason_; 70 RejectionReason rejection_reason_;
72 71
73 private: 72 private:
74 DISALLOW_COPY_AND_ASSIGN(ThirdPartyAuthenticatorBase); 73 DISALLOW_COPY_AND_ASSIGN(ThirdPartyAuthenticatorBase);
75 }; 74 };
76 75
77 } // namespace protocol 76 } // namespace protocol
78 } // namespace remoting 77 } // namespace remoting
79 78
80 #endif // REMOTING_PROTOCOL_THIRD_PARTY_AUTHENTICATOR_BASE_H_ 79 #endif // REMOTING_PROTOCOL_THIRD_PARTY_AUTHENTICATOR_BASE_H_
OLDNEW
« no previous file with comments | « remoting/protocol/ssl_hmac_channel_authenticator.h ('k') | remoting/protocol/third_party_authenticator_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698