• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Determine if user can admin
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Determine if user can admin


  • Subject: Re: Determine if user can admin
  • From: Markus Hitter <email@hidden>
  • Date: Tue, 19 Apr 2005 09:47:01 +0200


Am 19.04.2005 um 01:44 schrieb Eric Long:

When setting up accounts in Mac OS X, the Accounts pref panel has a checkbox
for user accounts labeled, "Allow user to administer this computer".

This is a checkbox wether the user is member of the group "admin" or not.


How can I programmatically determine if my application is being run for a
user who is allowed to administer the computer vs. one who isn't?

1) Something like "id | grep admin".

2) Try to execute you task anyways and watch for errors.

3) Ask for privileged execution always. This would allow admins, currently logged in as somebody else, as well.

Guys like myself do their work as an unprivileged user just to be sure to get asked for a password before some app tries to "improve" the system. :-)


HTH, Markus

- - - - - - - - - - - - - - - - - - -
Dipl. Ing. Markus Hitter
http://www.jump-ing.de/



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Determine if user can admin
      • From: Eric Long <email@hidden>
References: 
 >Determine if user can admin (From: Eric Long <email@hidden>)

  • Prev by Date: RE: passing buffer from User Client to Driver
  • Next by Date: Re: Determine if user can admin
  • Previous by thread: Determine if user can admin
  • Next by thread: Re: Determine if user can admin
  • Index(es):
    • Date
    • Thread