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

Side by Side Diff: remoting/host/security_key/fake_remote_security_key_ipc_client.cc

Issue 2085353004: Update GnubbyAuthHandler to use the current session ID (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@host_extension
Patch Set: Updating a comment Created 4 years, 5 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 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 #include "remoting/host/security_key/fake_remote_security_key_ipc_client.h" 5 #include "remoting/host/security_key/fake_remote_security_key_ipc_client.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 IPC_MESSAGE_HANDLER(ChromotingNetworkToRemoteSecurityKeyMsg_Response, 99 IPC_MESSAGE_HANDLER(ChromotingNetworkToRemoteSecurityKeyMsg_Response,
100 OnSecurityKeyResponse) 100 OnSecurityKeyResponse)
101 IPC_MESSAGE_UNHANDLED(handled = false) 101 IPC_MESSAGE_UNHANDLED(handled = false)
102 IPC_END_MESSAGE_MAP() 102 IPC_END_MESSAGE_MAP()
103 103
104 CHECK(handled) << "Received unexpected IPC type: " << message.type(); 104 CHECK(handled) << "Received unexpected IPC type: " << message.type();
105 return handled; 105 return handled;
106 } 106 }
107 107
108 void FakeRemoteSecurityKeyIpcClient::OnChannelConnected(int32_t peer_pid) { 108 void FakeRemoteSecurityKeyIpcClient::OnChannelConnected(int32_t peer_pid) {
109 ipc_channel_connected_ = true;
109 channel_event_callback_.Run(); 110 channel_event_callback_.Run();
110 } 111 }
111 112
112 void FakeRemoteSecurityKeyIpcClient::OnChannelError() { 113 void FakeRemoteSecurityKeyIpcClient::OnChannelError() {
114 ipc_channel_connected_ = false;
113 channel_event_callback_.Run(); 115 channel_event_callback_.Run();
114 } 116 }
115 117
116 void FakeRemoteSecurityKeyIpcClient::OnConnectionDetails( 118 void FakeRemoteSecurityKeyIpcClient::OnConnectionDetails(
117 const std::string& channel_name) { 119 const std::string& channel_name) {
118 last_message_received_ = channel_name; 120 last_message_received_ = channel_name;
119 channel_event_callback_.Run(); 121 channel_event_callback_.Run();
120 } 122 }
121 123
122 void FakeRemoteSecurityKeyIpcClient::OnSecurityKeyResponse( 124 void FakeRemoteSecurityKeyIpcClient::OnSecurityKeyResponse(
123 const std::string& request_data) { 125 const std::string& request_data) {
124 last_message_received_ = request_data; 126 last_message_received_ = request_data;
125 channel_event_callback_.Run(); 127 channel_event_callback_.Run();
126 } 128 }
127 129
128 } // namespace remoting 130 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698