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

Side by Side Diff: remoting/host/security_key/security_key_ipc_server_impl.h

Issue 2468523003: Pass the desktop session ID to the remoting network process. (Closed)
Patch Set: rebase Created 4 years, 1 month 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 2016 The Chromium Authors. All rights reserved. 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 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_HOST_SECURITY_KEY_SECURITY_KEY_IPC_SERVER_IMPL_H_ 5 #ifndef REMOTING_HOST_SECURITY_KEY_SECURITY_KEY_IPC_SERVER_IMPL_H_
6 #define REMOTING_HOST_SECURITY_KEY_SECURITY_KEY_IPC_SERVER_IMPL_H_ 6 #define REMOTING_HOST_SECURITY_KEY_SECURITY_KEY_IPC_SERVER_IMPL_H_
7 7
8 #include "remoting/host/security_key/security_key_ipc_server.h" 8 #include "remoting/host/security_key/security_key_ipc_server.h"
9 9
10 #include <cstdint> 10 #include <cstdint>
(...skipping 18 matching lines...) Expand all
29 29
30 namespace remoting { 30 namespace remoting {
31 31
32 // Responsible for handing the server end of the IPC channel between the 32 // Responsible for handing the server end of the IPC channel between the
33 // the network process and the local remote_security_key process. 33 // the network process and the local remote_security_key process.
34 class SecurityKeyIpcServerImpl : public SecurityKeyIpcServer, 34 class SecurityKeyIpcServerImpl : public SecurityKeyIpcServer,
35 public IPC::Listener { 35 public IPC::Listener {
36 public: 36 public:
37 SecurityKeyIpcServerImpl( 37 SecurityKeyIpcServerImpl(
38 int connection_id, 38 int connection_id,
39 uint32_t peer_session_id, 39 ClientSessionDetails* client_session_details,
40 base::TimeDelta initial_connect_timeout, 40 base::TimeDelta initial_connect_timeout,
41 const SecurityKeyAuthHandler::SendMessageCallback& message_callback, 41 const SecurityKeyAuthHandler::SendMessageCallback& message_callback,
42 const base::Closure& done_callback); 42 const base::Closure& done_callback);
43 ~SecurityKeyIpcServerImpl() override; 43 ~SecurityKeyIpcServerImpl() override;
44 44
45 // SecurityKeyIpcServer implementation. 45 // SecurityKeyIpcServer implementation.
46 bool CreateChannel(const std::string& channel_name, 46 bool CreateChannel(const std::string& channel_name,
47 base::TimeDelta request_timeout) override; 47 base::TimeDelta request_timeout) override;
48 bool SendResponse(const std::string& message_data) override; 48 bool SendResponse(const std::string& message_data) override;
49 49
50 private: 50 private:
51 // IPC::Listener implementation. 51 // IPC::Listener implementation.
52 bool OnMessageReceived(const IPC::Message& message) override; 52 bool OnMessageReceived(const IPC::Message& message) override;
53 void OnChannelConnected(int32_t peer_pid) override; 53 void OnChannelConnected(int32_t peer_pid) override;
54 void OnChannelError() override; 54 void OnChannelError() override;
55 55
56 // Handles security key resquest IPC messages. 56 // Handles security key resquest IPC messages.
57 void OnSecurityKeyRequest(const std::string& request); 57 void OnSecurityKeyRequest(const std::string& request);
58 58
59 // The value assigned to identify the current IPC channel. 59 // The value assigned to identify the current IPC channel.
60 int connection_id_; 60 int connection_id_;
61 61
62 // The expected session id of the process connecting to the IPC channel. 62 // Interface which provides details about the client session.
63 uint32_t peer_session_id_; 63 ClientSessionDetails* client_session_details_ = nullptr;
64 64
65 // Tracks whether the connection is in the process of being closed. 65 // Tracks whether the connection is in the process of being closed.
66 bool connection_close_pending_ = false; 66 bool connection_close_pending_ = false;
67 67
68 // Timeout for disconnecting the IPC channel if there is no client activity. 68 // Timeout for disconnecting the IPC channel if there is no client activity.
69 base::TimeDelta initial_connect_timeout_; 69 base::TimeDelta initial_connect_timeout_;
70 70
71 // Timeout for disconnecting the IPC channel if there is no response from 71 // Timeout for disconnecting the IPC channel if there is no response from
72 // the remote client after a security key request. 72 // the remote client after a security key request.
73 base::TimeDelta security_key_request_timeout_; 73 base::TimeDelta security_key_request_timeout_;
(...skipping 14 matching lines...) Expand all
88 base::ThreadChecker thread_checker_; 88 base::ThreadChecker thread_checker_;
89 89
90 base::WeakPtrFactory<SecurityKeyIpcServerImpl> weak_factory_; 90 base::WeakPtrFactory<SecurityKeyIpcServerImpl> weak_factory_;
91 91
92 DISALLOW_COPY_AND_ASSIGN(SecurityKeyIpcServerImpl); 92 DISALLOW_COPY_AND_ASSIGN(SecurityKeyIpcServerImpl);
93 }; 93 };
94 94
95 } // namespace remoting 95 } // namespace remoting
96 96
97 #endif // REMOTING_HOST_SECURITY_KEY_SECURITY_KEY_IPC_SERVER_IMPL_H_ 97 #endif // REMOTING_HOST_SECURITY_KEY_SECURITY_KEY_IPC_SERVER_IMPL_H_
OLDNEW
« no previous file with comments | « remoting/host/security_key/security_key_ipc_server.cc ('k') | remoting/host/security_key/security_key_ipc_server_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698