[wp-hackers] Time to change GUID to UUID?
Eric Mann
eric at eam.me
Mon May 9 14:45:44 UTC 2011
Matt, great suggestion!
wp_hash() uses MD5 by default ... any reason to use SHA1 over MD5 for this
purpose?
If not, we could use $uid = wp_hash( microtime() . DB_NAME .
$post->post_title . $post->ID );
Or, perhaps even better, use a filter so that individual sites can override
it?
On Mon, May 9, 2011 at 6:40 AM, Matt Martz <matt at sivel.net> wrote:
> On Mon, May 9, 2011 at 8:29 AM, Dougal Campbell <dougal at gunters.org>
> wrote:
> > $uid = sha1 ( microtime() . AUTH_SALT . DB_NAME . $post->post_title .
> > $post->ID )
>
> While it is not sha1, the wp_hash function, will create a hash based
> off of one of the salts. Might as well use functions that already
> exist to perform tasks such as this.
>
> Not that I am weighing in on this topic, just including pertinent
> information where I see it :)
>
> --
> Matt Martz
> matt at sivel.net
> http://sivel.net/
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
More information about the wp-hackers
mailing list