non-root app writing to root file
non-root app writing to root file
- Subject: non-root app writing to root file
- From: Matt Jaffa <email@hidden>
- Date: Sat, 24 Jul 2004 18:26:31 -0600
Hi,
I was wondering if anybody has an example I could download or could
help me with this question.
I want to implement something similar to Apple's SystemPreferences,
where it has that lock that you can authenticate as an admin so that
you can change some of the root owned files found in
/Library/Preferences/...... . For example
/Library/Preferences/SystemConfiguration/preferences.plist behaves like
this, and the SystemPreference that changes this file is the Network
one.
So I want to perform similar actions, I have a root owned file stored
in a similar location and need that file to be modified by my system
preference, but they are run as the current user, so that is why I am
sure they have that Authorization/Authentication in the
Security.Framework, I have been reading up on it, but have found no
examples or help regarding being able to use Cocoa/Objective-C NSArray
writeToFile, or whatever those functions are. I have successfully
gotten that Authentication window to popup and return with the AuthRef,
but my code still can't do those writing to files , to the root files.
Any help,
Thanks,
Matt
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.