How are .NET 4 GUIDs generated?

Since Windows 2000 Microsoft uses a version 4 algorithm: With Windows 2000, Microsoft switched to version 4 GUIDs, since embedding the MAC address was viewed as a security risk. 1 You can see that as well from a GUID generated in .NET (from Wikipedia): Version 4 UUIDs have the form xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx with any hexadecimal digits … Read more

How does C# generate GUIDs?

There’s a really good article on Raymond Chen’s blog that describes how GUIDs are generated, and in particular why a substring of a guid is not guaranteed to be unique. Basically, a a GUID is generated using a combination of: The MAC address of the machine used to generate the GUID (so GUIDs generated on … Read more

Print a GUID variable

Use the StringFromCLSID function to convert it to a string e.g.: GUID guid; CoCreateGuid(&guid); OLECHAR* guidString; StringFromCLSID(guid, &guidString); // use guidString… // ensure memory is freed ::CoTaskMemFree(guidString); Also see the MSDN definition of a GUID for a description of data4, which is an array containing the last 8 bytes of the GUID

How do I obtain/use LibUUID?

In Ubuntu, you can do apt-cache search libuuid to see the available packages relating to the text libuuid. Here’s my output from Ubuntu 9.04: $ apt-cache search libuuid libuuid-perl – Perl extension for using UUID interfaces as defined in e2fsprogs libuuid1 – universally unique id library libuuid1-dbg – Debugging information for libuuid1 uuid-dev – universally … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)