Add gen_random_uuid() to contrib/pgcrypto.

Tom Lane <tgl@sss.pgh.pa.us>

Commit: e6170126fc201052b0ec5fc92177eb181d602d26
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: 2014-01-17T21:52:06Z
Releases: 9.4.0
Add gen_random_uuid() to contrib/pgcrypto.

This function provides a way of generating version 4 (pseudorandom) UUIDs
based on pgcrypto's PRNG.  The main reason for doing this is that the
OSSP UUID library depended on by contrib/uuid-ossp is becoming more and
more of a porting headache, so we need an alternative for people who can't
install that.  A nice side benefit though is that this implementation is
noticeably faster than uuid-ossp's uuid_generate_v4() function.

Oskari Saarenmaa, reviewed by Emre Hasegeli

Files

PathChange+/−
contrib/pgcrypto/Makefile modified +1 −1
contrib/pgcrypto/pgcrypto--1.0--1.1.sql added +9 −0
contrib/pgcrypto/pgcrypto--1.1.sql (from contrib/pgcrypto/pgcrypto--1.0.sql) renamed +6 −1
contrib/pgcrypto/pgcrypto.c modified +27 −0
contrib/pgcrypto/pgcrypto.control modified +1 −1
contrib/pgcrypto/pgcrypto.h modified +1 −0
doc/src/sgml/datatype.sgml modified +2 −0
doc/src/sgml/pgcrypto.sgml modified +11 −0
doc/src/sgml/uuid-ossp.sgml modified +9 −0