Turns on SSL/TLS and optional row-level encryption so ParadeDB traffic and data stay unreadable to outsiders.
Encryption protects data in transit (client ↔ server) and at rest (on disk). When ParadeDB is used for similarity search, vectors often contain sensitive customer signals that must stay private.
Set ssl = on
in postgresql.conf
, provide a server certificate, and reload the service. ParadeDB automatically inherits the cluster-wide SSL configuration.
1) Copy server.crt
and server.key
into $PGDATA
.
2) Run chmod 600 server.key
.
3) Edit postgresql.conf
: ssl = on
.
4) Restart PostgreSQL: sudo systemctl restart postgresql
.
Use the pgcrypto
extension. ParadeDB indexes encrypted payloads as bytea, so vectors remain functional while raw text stays hidden.
Create a symmetric key, encrypt customer e-mails, and keep search vectors readable:
CREATE EXTENSION IF NOT EXISTS pgcrypto;
ALTER TABLE Customers ADD COLUMN email_enc bytea;
UPDATE Customers
SET email_enc = pgp_sym_encrypt(email, 'aes-key-123');
ALTER TABLE Customers ALTER COLUMN email DROP NOT NULL;
Yes. Store the cleartext in a separate vector column while keeping the original sensitive field encrypted. This pattern satisfies both privacy and search performance.
• Rotate SSL certificates yearly.
• Store encryption keys in a secrets manager, not in source control.
• Re-encrypt data after key rotation.
• Enable ssl_prefer_server_ciphers = on
for stronger handshakes.
Negligibly. Modern CPUs handle TLS handshakes quickly; once a session is established, query latency increase is usually <2%.
Yes. Set ssl_ca_file
, ssl_cert_file
, and hostssl
lines in pg_hba.conf
with cert
authentication.
Add a new key, decrypt with the old, encrypt with the new in a single transaction, then drop the old key.