Re: Preferences, Authorization, Writing files
Re: Preferences, Authorization, Writing files
- Subject: Re: Preferences, Authorization, Writing files
- From: Chris Hanson <email@hidden>
- Date: Fri, 7 Feb 2003 10:05:33 -0600
At 7:38 PM -0700 2/6/03, Frank Fenn wrote:
5) Now I change some settings and want to overwrite the existing
data but this will fail, since a normal user has no write access
to the directories mentioned above. But even with authentication
services (which rights shall I obtain?) and an admin user name
password the NSArchive operation failed. What am I doing wrong here?
It sounds like you're assuming that Authorization Services will grant
privileges to your preference pane. It won't. In Unix privileges
can't be granted to running processes, they can only be granted to
new processes or reduced for running processes.
To write your data, you'll need to run a small helper utility with
administrator privileges using Authorization Services. There's
sample code on Apple's web site demonstrating how to do this.
-- Chris
--
Chris Hanson, bDistributed.com, Inc. | Email: email@hidden
Custom Application Development | Phone: +1-847-372-3955
http://bdistributed.com/ | Fax: +1-847-589-3738
http://bdistributed.com/Articles/ | Personal Email: email@hidden
_______________________________________________
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.