• 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: Security Framework: Authori(s/z)ion Rights
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Security Framework: Authori(s/z)ion Rights


  • Subject: Re: Security Framework: Authori(s/z)ion Rights
  • From: Nick Zitzmann <email@hidden>
  • Date: Fri, 7 Nov 2003 21:30:22 -0800

On Nov 7, 2003, at 7:49 AM, Huyler, Christopher M wrote:

Can anyone answer these questions?????

Sorry, not me. I've only used the default rights with the Authorization functions...

3) If all I have is a user name, is there a way to check to see that the
user is an administrator?

But this one I can answer: Call the function "getgrouplist()" with the user's "short" name as the first parameter, and check to see if the user belongs to group #80, which is the gid for the "admin" group in OS X. If the user belongs to that group, then the user is an admin. See the man page for getgrouplist(3) for details...

Nick Zitzmann
AIM/iChat: dragonsdontsleep
Check out my software page: http://seiryu.home.comcast.net/
S/MIME signature available upon request

"I have always wished that my computer would be as easy to use as my telephone. My wish has come true. I no longer know how to use my telephone." - Bjarne Stroustrup
_______________________________________________
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.
References: 
 >RE: Re: Security Framework: Authori(s/z)ion Rights (From: "Huyler, Christopher M" <email@hidden>)

  • Prev by Date: Blue default button?
  • Next by Date: Re: NSXMLParser and dtds (UPDATE)
  • Previous by thread: RE: Re: Security Framework: Authori(s/z)ion Rights
  • Next by thread: RE: Security Framework: Authori(s/z)ion Rights
  • Index(es):
    • Date
    • Thread