Re: NSTask as root
Re: NSTask as root
- Subject: Re: NSTask as root
- From: Stephan Ruggiero <email@hidden>
- Date: Fri, 18 Mar 2005 09:54:32 +0100
Hi,
I've been messing around with this problem for wuite a while now and I
found the BLAuthentication class the most convenient way to do it. Do a
Google search and you will find places to download the class. You just
have to call the "executeCommand" method to have the user authorize and
then "sudo" the task.
I also read that some think BLAuthentication is a "dirty" way to
implement root tasks, but I did not figure out any other convenient
way...
bye
Stephan
Am 18.03.2005 um 08:55 schrieb Rakka:
On Mar 18, 2005, at 6:32 PM, Ben Borofka wrote:
I need to run a series of NSTasks as root. I've found some samples
out there but they are old, complicated, confusing and C-based. Is
there an easy way of doing this in Objective-C? I'd like to just have
a standard Authentication dialogue pop up and then have a method go
and execute a bunch of NSTasks with those privileges. Is that a lot
of work?
Thanks.
Ben
I also prefer using NSTask opposed to the other methods (AEWP). What I
would do if I were you is to have the app relaunch as root, then run
your NSTasks. There are other ways though. But I find this way useful
for me as I have to execute a lot of different tasks.
Thanks
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
email@hidden
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden