20090628

Elevated Processes

Objective-c is an insecure language. Although the feature is being deprecated (I believe starting with Snow Leopard), a user may override a program's code.

An application that needs to perform a restricted action can prompt the user for Administrator password using the Security framework. However, for security reasons, the best methodology is to have a helper application, and launch it using the authorization obtained. This raises issues of setting +s on the helper tool and interprocess communication. Allegedly, all of these are very straightforward, but the Apple-provided BetterAuthorizationSample project is written in somewhat arcane C (there are goto statements!), and I find it very difficult to understand what's going on.

I would appreciate assistance, especially in the form of a non-Apple tutorial or documentation, indicating how to set up communication with an executable that is a secondary target in the same xcodeproj.

EDIT: Have now gotten helper application to launch. There was a typo in the filepath I passed to AEWP.

No comments:

Post a Comment