mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-08-22 00:33:23 +02:00
This was from before the hex format was available in bytea. Now we can remove the extra explicit encoding/decoding calls and rely on the default output format. Discussion: https://www.postgresql.org/message-id/flat/17dcb4f7-7ac1-e2b6-d5f7-2dfba06cd9ee%40enterprisedb.com
12 lines
200 B
SQL
12 lines
200 B
SQL
--
|
|
-- init pgcrypto
|
|
--
|
|
|
|
CREATE EXTENSION pgcrypto;
|
|
|
|
-- check error handling
|
|
select gen_salt('foo');
|
|
select digest('foo', 'foo');
|
|
select hmac('foo', 'foo', 'foo');
|
|
select encrypt('foo', 'foo', 'foo');
|