44-- ensure consistent test output regardless of the default bytea format
55SET bytea_output TO escape;
66select pgp_sym_decrypt(pgp_sym_encrypt('Secret.', 'key'), 'key');
7- ERROR: pg_random_bytes() is not supported by this build
7+ ERROR: generating random data is not supported by this build
88DETAIL: This functionality requires a source of strong random numbers
99HINT: You need to rebuild PostgreSQL using --enable-strong-random
1010-- check whether the defaults are ok
@@ -16,7 +16,7 @@ select pgp_sym_decrypt(pgp_sym_encrypt('Secret.', 'key'),
1616 expect-s2k-digest-algo=sha1,
1717 expect-compress-algo=0
1818 ');
19- ERROR: pg_random_bytes() is not supported by this build
19+ ERROR: generating random data is not supported by this build
2020DETAIL: This functionality requires a source of strong random numbers
2121HINT: You need to rebuild PostgreSQL using --enable-strong-random
2222-- maybe the expect- stuff simply does not work
@@ -28,134 +28,134 @@ select pgp_sym_decrypt(pgp_sym_encrypt('Secret.', 'key'),
2828 expect-s2k-digest-algo=md5,
2929 expect-compress-algo=1
3030 ');
31- ERROR: pg_random_bytes() is not supported by this build
31+ ERROR: generating random data is not supported by this build
3232DETAIL: This functionality requires a source of strong random numbers
3333HINT: You need to rebuild PostgreSQL using --enable-strong-random
3434-- bytea as text
3535select pgp_sym_decrypt(pgp_sym_encrypt_bytea('Binary', 'baz'), 'baz');
36- ERROR: pg_random_bytes() is not supported by this build
36+ ERROR: generating random data is not supported by this build
3737DETAIL: This functionality requires a source of strong random numbers
3838HINT: You need to rebuild PostgreSQL using --enable-strong-random
3939-- text as bytea
4040select pgp_sym_decrypt_bytea(pgp_sym_encrypt('Text', 'baz'), 'baz');
41- ERROR: pg_random_bytes() is not supported by this build
41+ ERROR: generating random data is not supported by this build
4242DETAIL: This functionality requires a source of strong random numbers
4343HINT: You need to rebuild PostgreSQL using --enable-strong-random
4444-- algorithm change
4545select pgp_sym_decrypt(
4646 pgp_sym_encrypt('Secret.', 'key', 'cipher-algo=bf'),
4747 'key', 'expect-cipher-algo=bf');
48- ERROR: pg_random_bytes() is not supported by this build
48+ ERROR: generating random data is not supported by this build
4949DETAIL: This functionality requires a source of strong random numbers
5050HINT: You need to rebuild PostgreSQL using --enable-strong-random
5151select pgp_sym_decrypt(
5252 pgp_sym_encrypt('Secret.', 'key', 'cipher-algo=aes'),
5353 'key', 'expect-cipher-algo=aes128');
54- ERROR: pg_random_bytes() is not supported by this build
54+ ERROR: generating random data is not supported by this build
5555DETAIL: This functionality requires a source of strong random numbers
5656HINT: You need to rebuild PostgreSQL using --enable-strong-random
5757select pgp_sym_decrypt(
5858 pgp_sym_encrypt('Secret.', 'key', 'cipher-algo=aes192'),
5959 'key', 'expect-cipher-algo=aes192');
60- ERROR: pg_random_bytes() is not supported by this build
60+ ERROR: generating random data is not supported by this build
6161DETAIL: This functionality requires a source of strong random numbers
6262HINT: You need to rebuild PostgreSQL using --enable-strong-random
6363-- s2k change
6464select pgp_sym_decrypt(
6565 pgp_sym_encrypt('Secret.', 'key', 's2k-mode=0'),
6666 'key', 'expect-s2k-mode=0');
67- ERROR: pg_random_bytes() is not supported by this build
67+ ERROR: generating random data is not supported by this build
6868DETAIL: This functionality requires a source of strong random numbers
6969HINT: You need to rebuild PostgreSQL using --enable-strong-random
7070select pgp_sym_decrypt(
7171 pgp_sym_encrypt('Secret.', 'key', 's2k-mode=1'),
7272 'key', 'expect-s2k-mode=1');
73- ERROR: pg_random_bytes() is not supported by this build
73+ ERROR: generating random data is not supported by this build
7474DETAIL: This functionality requires a source of strong random numbers
7575HINT: You need to rebuild PostgreSQL using --enable-strong-random
7676select pgp_sym_decrypt(
7777 pgp_sym_encrypt('Secret.', 'key', 's2k-mode=3'),
7878 'key', 'expect-s2k-mode=3');
79- ERROR: pg_random_bytes() is not supported by this build
79+ ERROR: generating random data is not supported by this build
8080DETAIL: This functionality requires a source of strong random numbers
8181HINT: You need to rebuild PostgreSQL using --enable-strong-random
8282-- s2k count change
8383select pgp_sym_decrypt(
8484 pgp_sym_encrypt('Secret.', 'key', 's2k-count=1024'),
8585 'key', 'expect-s2k-count=1024');
86- ERROR: pg_random_bytes() is not supported by this build
86+ ERROR: generating random data is not supported by this build
8787DETAIL: This functionality requires a source of strong random numbers
8888HINT: You need to rebuild PostgreSQL using --enable-strong-random
8989-- s2k_count rounds up
9090select pgp_sym_decrypt(
9191 pgp_sym_encrypt('Secret.', 'key', 's2k-count=65000000'),
9292 'key', 'expect-s2k-count=65000000');
93- ERROR: pg_random_bytes() is not supported by this build
93+ ERROR: generating random data is not supported by this build
9494DETAIL: This functionality requires a source of strong random numbers
9595HINT: You need to rebuild PostgreSQL using --enable-strong-random
9696-- s2k digest change
9797select pgp_sym_decrypt(
9898 pgp_sym_encrypt('Secret.', 'key', 's2k-digest-algo=md5'),
9999 'key', 'expect-s2k-digest-algo=md5');
100- ERROR: pg_random_bytes() is not supported by this build
100+ ERROR: generating random data is not supported by this build
101101DETAIL: This functionality requires a source of strong random numbers
102102HINT: You need to rebuild PostgreSQL using --enable-strong-random
103103select pgp_sym_decrypt(
104104 pgp_sym_encrypt('Secret.', 'key', 's2k-digest-algo=sha1'),
105105 'key', 'expect-s2k-digest-algo=sha1');
106- ERROR: pg_random_bytes() is not supported by this build
106+ ERROR: generating random data is not supported by this build
107107DETAIL: This functionality requires a source of strong random numbers
108108HINT: You need to rebuild PostgreSQL using --enable-strong-random
109109-- sess key
110110select pgp_sym_decrypt(
111111 pgp_sym_encrypt('Secret.', 'key', 'sess-key=0'),
112112 'key', 'expect-sess-key=0');
113- ERROR: pg_random_bytes() is not supported by this build
113+ ERROR: generating random data is not supported by this build
114114DETAIL: This functionality requires a source of strong random numbers
115115HINT: You need to rebuild PostgreSQL using --enable-strong-random
116116select pgp_sym_decrypt(
117117 pgp_sym_encrypt('Secret.', 'key', 'sess-key=1'),
118118 'key', 'expect-sess-key=1');
119- ERROR: pg_random_bytes() is not supported by this build
119+ ERROR: generating random data is not supported by this build
120120DETAIL: This functionality requires a source of strong random numbers
121121HINT: You need to rebuild PostgreSQL using --enable-strong-random
122122select pgp_sym_decrypt(
123123 pgp_sym_encrypt('Secret.', 'key', 'sess-key=1, cipher-algo=bf'),
124124 'key', 'expect-sess-key=1, expect-cipher-algo=bf');
125- ERROR: pg_random_bytes() is not supported by this build
125+ ERROR: generating random data is not supported by this build
126126DETAIL: This functionality requires a source of strong random numbers
127127HINT: You need to rebuild PostgreSQL using --enable-strong-random
128128select pgp_sym_decrypt(
129129 pgp_sym_encrypt('Secret.', 'key', 'sess-key=1, cipher-algo=aes192'),
130130 'key', 'expect-sess-key=1, expect-cipher-algo=aes192');
131- ERROR: pg_random_bytes() is not supported by this build
131+ ERROR: generating random data is not supported by this build
132132DETAIL: This functionality requires a source of strong random numbers
133133HINT: You need to rebuild PostgreSQL using --enable-strong-random
134134select pgp_sym_decrypt(
135135 pgp_sym_encrypt('Secret.', 'key', 'sess-key=1, cipher-algo=aes256'),
136136 'key', 'expect-sess-key=1, expect-cipher-algo=aes256');
137- ERROR: pg_random_bytes() is not supported by this build
137+ ERROR: generating random data is not supported by this build
138138DETAIL: This functionality requires a source of strong random numbers
139139HINT: You need to rebuild PostgreSQL using --enable-strong-random
140140-- no mdc
141141select pgp_sym_decrypt(
142142 pgp_sym_encrypt('Secret.', 'key', 'disable-mdc=1'),
143143 'key', 'expect-disable-mdc=1');
144- ERROR: pg_random_bytes() is not supported by this build
144+ ERROR: generating random data is not supported by this build
145145DETAIL: This functionality requires a source of strong random numbers
146146HINT: You need to rebuild PostgreSQL using --enable-strong-random
147147-- crlf
148148select encode(pgp_sym_decrypt_bytea(
149149 pgp_sym_encrypt(E'1\n2\n3\r\n', 'key', 'convert-crlf=1'),
150150 'key'), 'hex');
151- ERROR: pg_random_bytes() is not supported by this build
151+ ERROR: generating random data is not supported by this build
152152DETAIL: This functionality requires a source of strong random numbers
153153HINT: You need to rebuild PostgreSQL using --enable-strong-random
154154-- conversion should be lossless
155155select encode(digest(pgp_sym_decrypt(
156156 pgp_sym_encrypt(E'\r\n0\n1\r\r\n\n2\r', 'key', 'convert-crlf=1'),
157157 'key', 'convert-crlf=1'), 'sha1'), 'hex') as result,
158158 encode(digest(E'\r\n0\n1\r\r\n\n2\r', 'sha1'), 'hex') as expect;
159- ERROR: pg_random_bytes() is not supported by this build
159+ ERROR: generating random data is not supported by this build
160160DETAIL: This functionality requires a source of strong random numbers
161161HINT: You need to rebuild PostgreSQL using --enable-strong-random
0 commit comments