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

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

Issue 1643793002: Add policy to restrict client domain for Me2Me. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix remoting_perftests compile. Created 4 years, 10 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
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef REMOTING_PROTOCOL_REJECTING_AUTHENTICATOR_FACTORY_H_
6 #define REMOTING_PROTOCOL_REJECTING_AUTHENTICATOR_FACTORY_H_
7
8 #include <string>
9
10 #include "remoting/protocol/authenticator.h"
11
12 namespace remoting {
13 namespace protocol {
14
15 // Authenticator that accepts one message and rejects connection after that.
16 class RejectingAuthenticator : public Authenticator {
17 public:
18 RejectingAuthenticator(RejectionReason rejection_reason);
19 ~RejectingAuthenticator() override;
20
21 // Authenticator interface
22 State state() const override;
23 bool started() const override;
24 RejectionReason rejection_reason() const override;
25 void ProcessMessage(const buzz::XmlElement* message,
26 const base::Closure& resume_callback) override;
27 scoped_ptr<buzz::XmlElement> GetNextMessage() override;
28 const std::string& GetAuthKey() const override;
29 scoped_ptr<ChannelAuthenticator> CreateChannelAuthenticator() const override;
30
31 private:
32 RejectionReason rejection_reason_;
33 State state_ = WAITING_MESSAGE;
34 std::string auth_key_;
35
36 DISALLOW_COPY_AND_ASSIGN(RejectingAuthenticator);
37 };
38
39 } // namespace protocol
40 } // namespace remoting
41
42 #endif // REMOTING_PROTOCOL_REJECTING_AUTHENTICATOR_FACTORY_H_
OLDNEW
« no previous file with comments | « remoting/protocol/me2me_host_authenticator_factory.cc ('k') | remoting/protocol/rejecting_authenticator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698