Le 24 janv. 2010 à 10:19, Arun a écrit : > Hi All, > > I want to allow my cocoa app to be only launched by root/admin users. > How can i achieve this?
That's Unix, not Cocoa. Either set you app to owner root (chown -R root.wheel myapp) and then chmod to 744 (chmod -R 700 myapp), so that nobody but root can execute it, or you can check the user id with getuid at an early stage of your program (the superuser uid is 0). Type 'man getuid' in Terminal. Vincent_______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com