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

Unified Diff: remoting/protocol/connection_to_client.h

Issue 6594138: Block event processing on host/client until the client has authenticated. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix mock objects for unittests Created 9 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 side-by-side diff with in-line comments
Download patch
Index: remoting/protocol/connection_to_client.h
diff --git a/remoting/protocol/connection_to_client.h b/remoting/protocol/connection_to_client.h
index b7aa052c9a298282f093bb4eb8a9b48e39bcf9b7..901a5b185cc8dca0dd7d7762ad09ef68dbc72149 100644
--- a/remoting/protocol/connection_to_client.h
+++ b/remoting/protocol/connection_to_client.h
@@ -72,9 +72,12 @@ class ConnectionToClient :
// Return pointer to ClientStub.
virtual ClientStub* client_stub();
+ // Record whether the client has been properly authenticated with the host.
+ void SetClientAuthenticated(bool auth);
+
protected:
// Protected constructor used by unit test.
- ConnectionToClient();
+ //ConnectionToClient();
dmac 2011/03/04 01:36:27 should we get rid of this then?
garykac 2011/03/04 05:33:24 oops
private:
// Callback for protocol Session.
@@ -85,6 +88,11 @@ class ConnectionToClient :
void OnClosed();
+ // Initially false, this is set to true once the client has authenticated
+ // properly. When this is false, many client messages (like input events)
+ // will be silently ignored.
dmac 2011/03/04 01:36:27 will they be silently ignored? or will LOGs occur?
garykac 2011/03/04 05:33:24 They should LOG, so I removed "silently"
+ bool client_authenticated_;
+
// The libjingle channel used to send and receive data from the remote client.
scoped_refptr<Session> session_;

Powered by Google App Engine
This is Rietveld 408576698