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

Side by Side Diff: chromeos/dbus/debug_daemon_client.h

Issue 539273002: Added UI to enable debugging features on CrOS (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 (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 CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_ 5 #ifndef CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_
6 #define CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_ 6 #define CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/files/file.h" 9 #include "base/files/file.h"
10 #include "base/memory/ref_counted_memory.h" 10 #include "base/memory/ref_counted_memory.h"
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 virtual void TestICMP(const std::string& ip_address, 138 virtual void TestICMP(const std::string& ip_address,
139 const TestICMPCallback& callback) = 0; 139 const TestICMPCallback& callback) = 0;
140 140
141 // Tests ICMP connectivity to a specified host. The |ip_address| contains the 141 // Tests ICMP connectivity to a specified host. The |ip_address| contains the
142 // IPv4 or IPv6 address of the host, for example "8.8.8.8". 142 // IPv4 or IPv6 address of the host, for example "8.8.8.8".
143 virtual void TestICMPWithOptions( 143 virtual void TestICMPWithOptions(
144 const std::string& ip_address, 144 const std::string& ip_address,
145 const std::map<std::string, std::string>& options, 145 const std::map<std::string, std::string>& options,
146 const TestICMPCallback& callback) = 0; 146 const TestICMPCallback& callback) = 0;
147 147
148 // Called once EnableDebuggingFeatures() is complete. |succeeded| will be true
149 // if debugging features have been successfully enabled.
150 typedef base::Callback<void(bool succeeded)> EnableDebuggingCallback;
151
152 // Removes rootfs verification from the file system. Can be only called in
153 // dev mode.
154 virtual void RemoveRootfsVerification(
155 const EnableDebuggingCallback& callback) = 0;
156
157 // Enables debugging features (sshd, boot from USB). |password| is a new
158 // password for root user. Can be only called in dev mode.
159 virtual void EnableDebuggingFeatures(
160 const std::string& password,
161 const EnableDebuggingCallback& callback) = 0;
162
148 // Trigger uploading of crashes. 163 // Trigger uploading of crashes.
149 virtual void UploadCrashes() = 0; 164 virtual void UploadCrashes() = 0;
150 165
151 // Factory function, creates a new instance and returns ownership. 166 // Factory function, creates a new instance and returns ownership.
152 // For normal usage, access the singleton via DBusThreadManager::Get(). 167 // For normal usage, access the singleton via DBusThreadManager::Get().
153 static DebugDaemonClient* Create(); 168 static DebugDaemonClient* Create();
154 169
155 protected: 170 protected:
156 // Create() should be used instead. 171 // Create() should be used instead.
157 DebugDaemonClient(); 172 DebugDaemonClient();
158 173
159 private: 174 private:
160 DISALLOW_COPY_AND_ASSIGN(DebugDaemonClient); 175 DISALLOW_COPY_AND_ASSIGN(DebugDaemonClient);
161 }; 176 };
162 177
163 } // namespace chromeos 178 } // namespace chromeos
164 179
165 #endif // CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_ 180 #endif // CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698