hawq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From h...@apache.org
Subject incubator-hawq git commit: HAWQ-833. Lack of pgcrypto.sql for the pgcrypto support
Date Tue, 21 Jun 2016 01:57:18 GMT
Repository: incubator-hawq
Updated Branches:
  refs/heads/master 815e674ae -> dbdabfb73


HAWQ-833. Lack of pgcrypto.sql for the pgcrypto support


Project: http://git-wip-us.apache.org/repos/asf/incubator-hawq/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-hawq/commit/dbdabfb7
Tree: http://git-wip-us.apache.org/repos/asf/incubator-hawq/tree/dbdabfb7
Diff: http://git-wip-us.apache.org/repos/asf/incubator-hawq/diff/dbdabfb7

Branch: refs/heads/master
Commit: dbdabfb73ed254eb9e6480272ec0c68ae059b0ff
Parents: 815e674
Author: Paul Guo <paulguo@gmail.com>
Authored: Fri Jun 17 16:55:08 2016 +0800
Committer: Ruilong Huo <rhuo@pivotal.io>
Committed: Tue Jun 21 09:58:50 2016 +0800

----------------------------------------------------------------------
 contrib/pgcrypto.patch | 290 ++++++++++++++++++++++++++++++++++++++++++--
 1 file changed, 279 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/dbdabfb7/contrib/pgcrypto.patch
----------------------------------------------------------------------
diff --git a/contrib/pgcrypto.patch b/contrib/pgcrypto.patch
index eb650ca..96fb612 100644
--- a/contrib/pgcrypto.patch
+++ b/contrib/pgcrypto.patch
@@ -1,25 +1,32 @@
 diff --git a/contrib/pgcrypto/.gitignore b/contrib/pgcrypto/.gitignore
-index 5dcb3ff..dd80948 100644
+index 5dcb3ff..0b66753 100644
 --- a/contrib/pgcrypto/.gitignore
 +++ b/contrib/pgcrypto/.gitignore
-@@ -1,4 +1,9 @@
- # Generated subdirectories
--/log/
--/results/
--/tmp_check/
+@@ -2,3 +2,8 @@
+ /log/
+ /results/
+ /tmp_check/
 +libpgcrypto.a
 +libpgcrypto.so
 +libpgcrypto.so.0
 +libpgcrypto.so.0.0
 +pgcrypto.sql
-+log
-+results
-+tmp_check
 diff --git a/contrib/pgcrypto/Makefile b/contrib/pgcrypto/Makefile
-index dadec95..3ec597d 100644
+index dadec95..cfae9c9 100644
 --- a/contrib/pgcrypto/Makefile
 +++ b/contrib/pgcrypto/Makefile
-@@ -41,8 +41,8 @@ PG_CONFIG = pg_config
+@@ -26,7 +26,9 @@ MODULE_big	= pgcrypto
+ OBJS		= $(SRCS:.c=.o)
+ 
+ EXTENSION = pgcrypto
+-DATA = pgcrypto--1.0.sql pgcrypto--unpackaged--1.0.sql
++DATA_built  = pgcrypto.sql
++#DATA = pgcrypto--1.0.sql pgcrypto--unpackaged--1.0.sql
++DATA = uninstall_pgcrypto.sql
+ 
+ REGRESS = init md5 sha1 hmac-md5 hmac-sha1 blowfish rijndael \
+ 	$(CF_TESTS) \
+@@ -41,8 +43,8 @@ PG_CONFIG = pg_config
  PGXS := $(shell $(PG_CONFIG) --pgxs)
  include $(PGXS)
  else
@@ -30,3 +37,264 @@ index dadec95..3ec597d 100644
  include $(top_builddir)/src/Makefile.global
  include $(top_srcdir)/contrib/contrib-global.mk
  endif
+diff --git a/contrib/pgcrypto/pgcrypto.sql.in b/contrib/pgcrypto/pgcrypto.sql.in
+new file mode 100644
+index 0000000..8388e86
+--- /dev/null
++++ b/contrib/pgcrypto/pgcrypto.sql.in
+@@ -0,0 +1,203 @@
++/* $PostgreSQL: pgsql/contrib/pgcrypto/pgcrypto.sql.in,v 1.15 2007/11/13 04:24:28 momjian
Exp $ */
++
++-- Adjust this setting to control where the objects get created.
++SET search_path = public;
++
++CREATE OR REPLACE FUNCTION digest(text, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_digest'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION digest(bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_digest'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION hmac(text, text, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_hmac'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION hmac(bytea, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_hmac'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION crypt(text, text)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pg_crypt'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION gen_salt(text)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pg_gen_salt'
++LANGUAGE C VOLATILE STRICT;
++
++CREATE OR REPLACE FUNCTION gen_salt(text, int4)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pg_gen_salt_rounds'
++LANGUAGE C VOLATILE STRICT;
++
++CREATE OR REPLACE FUNCTION encrypt(bytea, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_encrypt'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION decrypt(bytea, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_decrypt'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION encrypt_iv(bytea, bytea, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_encrypt_iv'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION decrypt_iv(bytea, bytea, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_decrypt_iv'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION gen_random_bytes(int4)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_random_bytes'
++LANGUAGE 'C' VOLATILE STRICT;
++
++--
++-- pgp_sym_encrypt(data, key)
++--
++CREATE OR REPLACE FUNCTION pgp_sym_encrypt(text, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_sym_encrypt_text'
++LANGUAGE C STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_sym_encrypt_bytea(bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_sym_encrypt_bytea'
++LANGUAGE C STRICT;
++
++--
++-- pgp_sym_encrypt(data, key, args)
++--
++CREATE OR REPLACE FUNCTION pgp_sym_encrypt(text, text, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_sym_encrypt_text'
++LANGUAGE C STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_sym_encrypt_bytea(bytea, text, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_sym_encrypt_bytea'
++LANGUAGE C STRICT;
++
++--
++-- pgp_sym_decrypt(data, key)
++--
++CREATE OR REPLACE FUNCTION pgp_sym_decrypt(bytea, text)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pgp_sym_decrypt_text'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_sym_decrypt_bytea(bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_sym_decrypt_bytea'
++LANGUAGE C IMMUTABLE STRICT;
++
++--
++-- pgp_sym_decrypt(data, key, args)
++--
++CREATE OR REPLACE FUNCTION pgp_sym_decrypt(bytea, text, text)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pgp_sym_decrypt_text'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_sym_decrypt_bytea(bytea, text, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_sym_decrypt_bytea'
++LANGUAGE C IMMUTABLE STRICT;
++
++--
++-- pgp_pub_encrypt(data, key)
++--
++CREATE OR REPLACE FUNCTION pgp_pub_encrypt(text, bytea)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_pub_encrypt_text'
++LANGUAGE C STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_pub_encrypt_bytea(bytea, bytea)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_pub_encrypt_bytea'
++LANGUAGE C STRICT;
++
++--
++-- pgp_pub_encrypt(data, key, args)
++--
++CREATE OR REPLACE FUNCTION pgp_pub_encrypt(text, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_pub_encrypt_text'
++LANGUAGE C STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_pub_encrypt_bytea(bytea, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_pub_encrypt_bytea'
++LANGUAGE C STRICT;
++
++--
++-- pgp_pub_decrypt(data, key)
++--
++CREATE OR REPLACE FUNCTION pgp_pub_decrypt(bytea, bytea)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pgp_pub_decrypt_text'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_pub_decrypt_bytea(bytea, bytea)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_pub_decrypt_bytea'
++LANGUAGE C IMMUTABLE STRICT;
++
++--
++-- pgp_pub_decrypt(data, key, psw)
++--
++CREATE OR REPLACE FUNCTION pgp_pub_decrypt(bytea, bytea, text)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pgp_pub_decrypt_text'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_pub_decrypt_bytea(bytea, bytea, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_pub_decrypt_bytea'
++LANGUAGE C IMMUTABLE STRICT;
++
++--
++-- pgp_pub_decrypt(data, key, psw, arg)
++--
++CREATE OR REPLACE FUNCTION pgp_pub_decrypt(bytea, bytea, text, text)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pgp_pub_decrypt_text'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION pgp_pub_decrypt_bytea(bytea, bytea, text, text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pgp_pub_decrypt_bytea'
++LANGUAGE C IMMUTABLE STRICT;
++
++--
++-- PGP key ID
++--
++CREATE OR REPLACE FUNCTION pgp_key_id(bytea)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pgp_key_id_w'
++LANGUAGE C IMMUTABLE STRICT;
++
++--
++-- pgp armor
++--
++CREATE OR REPLACE FUNCTION armor(bytea)
++RETURNS text
++AS 'MODULE_PATHNAME', 'pg_armor'
++LANGUAGE C IMMUTABLE STRICT;
++
++CREATE OR REPLACE FUNCTION dearmor(text)
++RETURNS bytea
++AS 'MODULE_PATHNAME', 'pg_dearmor'
++LANGUAGE C IMMUTABLE STRICT;
++
+diff --git a/contrib/pgcrypto/uninstall_pgcrypto.sql b/contrib/pgcrypto/uninstall_pgcrypto.sql
+new file mode 100644
+index 0000000..a2891f6
+--- /dev/null
++++ b/contrib/pgcrypto/uninstall_pgcrypto.sql
+@@ -0,0 +1,46 @@
++/* $PostgreSQL: pgsql/contrib/pgcrypto/uninstall_pgcrypto.sql,v 1.4 2007/11/13 04:24:28
momjian Exp $ */
++
++-- Adjust this setting to control where the objects get dropped.
++SET search_path = public;
++
++DROP FUNCTION digest(text, text);
++DROP FUNCTION digest(bytea, text);
++
++DROP FUNCTION hmac(text, text, text);
++DROP FUNCTION hmac(bytea, bytea, text);
++
++DROP FUNCTION crypt(text, text);
++DROP FUNCTION gen_salt(text);
++DROP FUNCTION gen_salt(text, int4);
++
++DROP FUNCTION encrypt(bytea, bytea, text);
++DROP FUNCTION decrypt(bytea, bytea, text);
++DROP FUNCTION encrypt_iv(bytea, bytea, bytea, text);
++DROP FUNCTION decrypt_iv(bytea, bytea, bytea, text);
++
++DROP FUNCTION gen_random_bytes(int4);
++
++DROP FUNCTION pgp_sym_encrypt(text, text);
++DROP FUNCTION pgp_sym_encrypt_bytea(bytea, text);
++DROP FUNCTION pgp_sym_encrypt(text, text, text);
++DROP FUNCTION pgp_sym_encrypt_bytea(bytea, text, text);
++DROP FUNCTION pgp_sym_decrypt(bytea, text);
++DROP FUNCTION pgp_sym_decrypt_bytea(bytea, text);
++DROP FUNCTION pgp_sym_decrypt(bytea, text, text);
++DROP FUNCTION pgp_sym_decrypt_bytea(bytea, text, text);
++
++DROP FUNCTION pgp_pub_encrypt(text, bytea);
++DROP FUNCTION pgp_pub_encrypt_bytea(bytea, bytea);
++DROP FUNCTION pgp_pub_encrypt(text, bytea, text);
++DROP FUNCTION pgp_pub_encrypt_bytea(bytea, bytea, text);
++DROP FUNCTION pgp_pub_decrypt(bytea, bytea);
++DROP FUNCTION pgp_pub_decrypt_bytea(bytea, bytea);
++DROP FUNCTION pgp_pub_decrypt(bytea, bytea, text);
++DROP FUNCTION pgp_pub_decrypt_bytea(bytea, bytea, text);
++DROP FUNCTION pgp_pub_decrypt(bytea, bytea, text, text);
++DROP FUNCTION pgp_pub_decrypt_bytea(bytea, bytea, text, text);
++
++DROP FUNCTION pgp_key_id(bytea);
++DROP FUNCTION armor(bytea);
++DROP FUNCTION dearmor(text);
++


Mime
View raw message