Re: Get the UUID of the current user
Re: Get the UUID of the current user
- Subject: Re: Get the UUID of the current user
- From: Yoann GINI <email@hidden>
- Date: Wed, 25 Jun 2008 13:38:19 +0200
A friend have teach me this options after send my mail, and in
dsmbrutil.c I've found mbr_user_name_to_uuid() rather than
mbr_uid_to_uuid(), but I haven't find mbr_user_name_to_uuid() in
membership.h :-(
But I take note of that "look in Darwin's code" :-)
Le 25 juin 08 à 12:47, Michael Watson a écrit :
Jean-Daniel already provided an answer, but it's worth reminding
people that the source code to many of the utilities that come with
Mac OS X is available for dissection, including the Directory
Services utilities:
http://www.opensource.apple.com/darwinsource/10.5/DSTools-109/dsmbrutil/dsmbrutil.c
If you can do it on the command-line with an open-source tool, you
can extract the original code and use it directly. Your application
will perform better, it will have fewer external tool version
dependencies, and you can customize the data all you like without
performing any additional shell tool parsing.
--
m-s
On 25 Jun, 2008, at 05:22, Yoann GINI wrote:
Hi all,
I look for get the UUID of the current user, the only way actually
found is to run a NSTask with this command : "dsmemberutil getuuid -
U `whoami`"... But it's not really a good solution for me.
Have you a idea for get the UUID without NSTask ?
Thanks in advance,
Yoann
_______________________________________________
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
_______________________________________________
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