An Introduction To pgcrypto
summary
Shows how to install pgcrypto on Ubuntu Bionic, add CREATE EXTENSION pgcrypto, and use OpenPGP via gpg2; demonstrates digest() for MD5/SHA‑256, password hashing with salts (recommend SHA‑256 and SCRAM), gen_random_bytes() and gen_random_uuid(), and pgp public key workflow including exporting keys and running pgp_pub_encrypt()/pgp_pub_decrypt() in psql with d‑armor. Warns that raw symmetric encrypt/decrypt requires manual encode/decode, lacks integrity or signing, and that encryption raises CPU cost so selective use and never storing credit card data in plaintext are advised.
AI-written summary · about
chapters (10)
- 0:00Introduction to pg crypto
- 1:33Installation and setup
- 4:02Hashing and checksums
- 7:15Overview of crypto functions
- 11:00HMAC and data encoding
- 13:51Password hashing techniques
- 15:39Random data and UUIDs
- 18:11Symmetric encryption
- 20:31Asymmetric PGP encryption
- 23:56Performance and best practices
related talks
35mSecuring PostgreSQL From External Attack
50mSecuring PostgreSQL From External Attack
54mConfiguration and Authentication
48mAdvanced Authentication and Encrypted Connections
29mA comparison of PostgreSQL Encryption Options
07mAll about Postgres security
32mPostgreSQL Security: Defending Against External Attacks
48mColumn encryption solutions and ideas
