• 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: [iPhone] How to create a unique string
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [iPhone] How to create a unique string


  • Subject: Re: [iPhone] How to create a unique string
  • From: Douglas Davidson <email@hidden>
  • Date: Thu, 13 May 2010 08:59:26 -0700

On May 13, 2010, at 8:52 AM, Louis Gerbarg wrote:

>>> No it's not, as can easily be proven by observing that there are only a finite number of 40 character strings.  A UUID is probabilistically unique.
>>
>> CFUUID includes the MAC address, so unless your MAC address is cloned
>> or you manage to generate two UUIDs on the same device in the same
>> 100ns time interval or the calendar rolls over (which will take about
>> 3700 years), they are entirely unique within the universe of CFUUID
>> strings.
>
> No, it doesn't use the MAC address. MAC addresses are uses as part of type 1 uuids, CFUUID has generated type 4 (random) uuids by default since Tiger, and has always generated type 4 on iPhone. If you look at the source to CF there is a way to force it to generate type 1 uuids, but I doubt that is supported.

The use of the MAC address was removed because of privacy concerns.  CFUUID generation is only probabilistically unique, but the probability of collisions is vanishingly small.

Douglas Davidson

_______________________________________________

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

References: 
 >[iPhone] How to create a unique string (From: Tharindu Madushanka <email@hidden>)
 >Re: [iPhone] How to create a unique string (From: John Pannell <email@hidden>)
 >Re: [iPhone] How to create a unique string (From: Jonathan del Strother <email@hidden>)
 >Re: [iPhone] How to create a unique string (From: Tharindu Madushanka <email@hidden>)
 >Re: [iPhone] How to create a unique string (From: Eric Gorr <email@hidden>)
 >Re: [iPhone] How to create a unique string (From: Thomas Davie <email@hidden>)
 >Re: [iPhone] How to create a unique string (From: Michael Ash <email@hidden>)
 >Re: [iPhone] How to create a unique string (From: Louis Gerbarg <email@hidden>)

  • Prev by Date: Re: [iPhone] How to create a unique string
  • Next by Date: Re: [iPhone] How to create a unique string
  • Previous by thread: Re: [iPhone] How to create a unique string
  • Next by thread: Re: [iPhone] How to create a unique string
  • Index(es):
    • Date
    • Thread