Re: determine Admin vs nonAdmin users
Re: determine Admin vs nonAdmin users
- Subject: Re: determine Admin vs nonAdmin users
- From: Andrew Oliver <email@hidden>
- Date: Sun, 23 Jan 2005 23:22:09 -0800
On 1/23/05 2:51 PM, "Gnarlodious" <email@hidden> wrote:
> Entity Graham Anderson spoke thus:
>
>> is there a 'do shell script' or applescript out there that determine if
>> the user has admin privs?
>
> "admin" is in words of (do shell script "id")
Works for a single host in a non-networked environment.
May not work if using a networked directory system such as NIS (where other
group names may be used), or if the local /etc/sudoers file has been
customized from the Apple default.
It's possible to set /etc/sudoers to allow a specific user to run a specific
app with elevated privileges. Checking the existence (or otherwise) of the
admin group is not sufficient. It is, however, about the best you can do
easily without parsing /etc/sudoers or a suck-it-and-see approach.
Andrew
:)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden