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

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

Issue 2724223003: Disconnect all users if too many connection requests are received for It2Me (Closed)
Patch Set: Fixing another non-Windows build error Created 3 years, 9 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 (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_IT2ME_HOST_AUTHENTICATOR_FACTORY_H_ 5 #ifndef REMOTING_PROTOCOL_IT2ME_HOST_AUTHENTICATOR_FACTORY_H_
6 #define REMOTING_PROTOCOL_IT2ME_HOST_AUTHENTICATOR_FACTORY_H_ 6 #define REMOTING_PROTOCOL_IT2ME_HOST_AUTHENTICATOR_FACTORY_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 10
(...skipping 10 matching lines...) Expand all
21 namespace protocol { 21 namespace protocol {
22 22
23 // It2MeHostAuthenticatorFactory implements AuthenticatorFactory and 23 // It2MeHostAuthenticatorFactory implements AuthenticatorFactory and
24 // understands both the V2 and legacy V1 authentication mechanisms. 24 // understands both the V2 and legacy V1 authentication mechanisms.
25 class It2MeHostAuthenticatorFactory : public AuthenticatorFactory { 25 class It2MeHostAuthenticatorFactory : public AuthenticatorFactory {
26 public: 26 public:
27 It2MeHostAuthenticatorFactory( 27 It2MeHostAuthenticatorFactory(
28 const std::string& local_cert, 28 const std::string& local_cert,
29 scoped_refptr<RsaKeyPair> key_pair, 29 scoped_refptr<RsaKeyPair> key_pair,
30 const std::string& access_code, 30 const std::string& access_code,
31 const ValidatingAuthenticator::ValidationCallback& callback); 31 const ValidatingAuthenticator::ValidationCallback& incoming_callback,
32 const ValidatingAuthenticator::ValidationCallback& accepted_callback);
32 ~It2MeHostAuthenticatorFactory() override; 33 ~It2MeHostAuthenticatorFactory() override;
33 34
34 // AuthenticatorFactory interface. 35 // AuthenticatorFactory interface.
35 std::unique_ptr<Authenticator> CreateAuthenticator( 36 std::unique_ptr<Authenticator> CreateAuthenticator(
36 const std::string& local_jid, 37 const std::string& local_jid,
37 const std::string& remote_jid) override; 38 const std::string& remote_jid) override;
38 39
39 private: 40 private:
40 std::string local_cert_; 41 std::string local_cert_;
41 scoped_refptr<RsaKeyPair> key_pair_; 42 scoped_refptr<RsaKeyPair> key_pair_;
42 std::string access_code_hash_; 43 std::string access_code_hash_;
43 ValidatingAuthenticator::ValidationCallback validation_callback_; 44 ValidatingAuthenticator::ValidationCallback incoming_callback_;
45 ValidatingAuthenticator::ValidationCallback accepted_callback_;
44 46
45 DISALLOW_COPY_AND_ASSIGN(It2MeHostAuthenticatorFactory); 47 DISALLOW_COPY_AND_ASSIGN(It2MeHostAuthenticatorFactory);
46 }; 48 };
47 49
48 } // namespace protocol 50 } // namespace protocol
49 } // namespace remoting 51 } // namespace remoting
50 52
51 #endif // REMOTING_PROTOCOL_IT2ME_HOST_AUTHENTICATOR_FACTORY_H_ 53 #endif // REMOTING_PROTOCOL_IT2ME_HOST_AUTHENTICATOR_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698