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

Unified Diff: chrome/installer/mac/app/AuthorizedInstall.h

Issue 2243863003: Added authorized install with a script to do the copy. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Changed to OO design Created 4 years, 4 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: chrome/installer/mac/app/AuthorizedInstall.h
diff --git a/chrome/installer/mac/app/AuthorizedInstall.h b/chrome/installer/mac/app/AuthorizedInstall.h
new file mode 100644
index 0000000000000000000000000000000000000000..bd695e84141770fcd2963a4649c48859035adeb1
--- /dev/null
+++ b/chrome/installer/mac/app/AuthorizedInstall.h
@@ -0,0 +1,25 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_INSTALLER_MAC_APP_AUTHORIZEDINSTALL_H_
Anna Zeng 2016/08/18 15:57:16 Is there a test file for this new class? Let's add
ivanhernandez 2016/08/22 15:34:49 Will probably be on the next patch :)
+#define CHROME_INSTALLER_MAC_APP_AUTHORIZEDINSTALL_H_
+
+#import <Foundation/Foundation.h>
+#import <Security/Security.h>
+
+@interface AuthorizedInstall : NSObject {
+ AuthorizationRef authRef_;
+ OSStatus status_;
+ FILE* communicationPipe_;
Anna Zeng 2016/08/18 15:57:16 authRef_, status_, and communicationPipe_ can all
ivanhernandez 2016/08/22 15:34:49 Done.
+}
+
+// Asks for user password and starts tool with privileged permissions.
+- (BOOL)authorizeInstallationTool;
Anna Zeng 2016/08/18 15:57:16 Can we make this the init function?
ivanhernandez 2016/08/22 15:34:49 Probably want to use a name other than init to bet
+
+// Allows this program to communicate with the child process.
+- (void)sendMessageToTool:(NSString*)message;
Anna Zeng 2016/08/18 15:57:16 I think the preferred API is a function that doesn
ivanhernandez 2016/08/22 15:34:49 Done.
+
+@end
+
+#endif // CHROME_INSTALLER_MAC_APP_AUTHORIZEDINSTALL_H_
« no previous file with comments | « no previous file | chrome/installer/mac/app/AuthorizedInstall.m » ('j') | chrome/installer/mac/app/AuthorizedInstall.m » ('J')

Powered by Google App Engine
This is Rietveld 408576698