• 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: Authentication only for non admin login.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Authentication only for non admin login.


  • Subject: Re: Authentication only for non admin login.
  • From: "ninad walvekar" <email@hidden>
  • Date: Fri, 18 Jul 2008 13:32:15 +0530

hi,
I think I have precisely mentioned what I want to do in the first 2 lines of
my previous post. To add to it my current implementation is asking for a
user name and password for admin as well as standard user login i want it to
ask for a user name and password only for and only for  standard user login.

Can anyone tell me a way to identify which user(root/admin/standard) has
logged?

On Fri, Jul 18, 2008 at 12:35 AM, Mike <email@hidden>
wrote:

> No one is going to help you if you don't describe exactly what it is you
> are trying to do. Authentication is a very difficult subject on OS X.
> Without a concise, clear explanation, you're not going to get any help.
>
> ninad walvekar wrote:
>
>> hi,
>>
>> I want to run an application such that it will pop-up for the admin user
>> name and password(authentication) when run by nonadmin (standard )login.
>>
>> let me explain what i am doing:-
>> - (BOOL)Authenticate {
>>
>>    AuthorizationRights     myRights;
>>    AuthorizationItem       myItems[1];
>>    AuthorizationRef        authorizationRef;
>>    OSStatus                err;
>>    AuthorizationFlags        authFlags =
>> kAuthorizationFlagInteractionAllowed | kAuthorizationFlagExtendRights;
>>    BOOL                    bRet;
>>
>>    myItems[0].name = kAuthorizationRightExecute;
>>    myItems[0].valueLength = 0;
>>    myItems[0].value = NULL;
>>    myItems[0].flags = 0;
>>
>>    char *  rmArgs[2];
>> //    int     status;
>>
>>    rmArgs[0] = "-l";
>>    rmArgs[1] = NULL;
>> //    rmArgs[2] = NULL;
>>
>>
>>    myRights.count = sizeof(myItems) / sizeof(myItems[0]);
>>    myRights.items = myItems;
>>
>>
>>    err = AuthorizationCreate(&myRights, kAuthorizationEmptyEnvironment,
>> authFlags, &authorizationRef);
>>
>>    return bRet;
>>
>> }
>> Can anyone tell the required modification so that i can make it work the
>> way
>> mentioned above or some other way by which i can achieve the needful.
>>
>> thanks in advance
>> _______________________________________________
>>
>> Cocoa-dev mailing list (email@hidden)
>>
>> 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:
>>
>>
>> This email sent to email@hidden
>>
>>
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Authentication only for non admin login.
      • From: "Michael Ash" <email@hidden>
References: 
 >RE:Authentication only for non admin login. (From: "ninad walvekar" <email@hidden>)

  • Prev by Date: Flip animation like dashboard widgets
  • Next by Date: Re: notification when app is moved
  • Previous by thread: RE:Authentication only for non admin login.
  • Next by thread: Re: Authentication only for non admin login.
  • Index(es):
    • Date
    • Thread