Config Files · 1 file

Sample pg_hba.conf File

pg_hba.conf controls PostgreSQL client authentication. Our sample is realistic and valid for its tool, with fake hosts and secrets.

pg_hba.conf · 649 B

PostgreSQL pg_hba.conf

PostgreSQL client-authentication rules: peer for local sockets, scram-sha-256 for the app subnet, TLS-only remote access and a replication line. All hosts, keys and secrets are fake.

CC0 · free for any use · Verified by an independent tool · Report a problem

pg_hba.conf — first lines
# Sample pg_hba.conf — samplefiles.com
# TYPE  DATABASE        USER            ADDRESS                 METHOD
local   all             postgres                                peer
local   all             all                                     scram-sha-256
host    all             all             127.0.0.1/32            scram-sha-256
host    all             all             ::1/128                 scram-sha-256
host    app             app             10.0.1.0/24             scram-sha-256
hostssl all             all             0.0.0.0/0               scram-sha-256
host    replication     replicator      10.0.2.10/32            scram-sha-256

File details

Size
649 B (649 bytes)
MIME type
text/plain
SHA-256
3147439a278b4dba95d48e2061c433aaa1d6376123e0b6aee352ff307c934e3d
MD5
8d41f950c93bc04886cd68fd7d17b71a

Download from the command line

curl -L -o pg_hba.conf https://files.samplefiles.com/config/pg-hba-conf/pg_hba.conf

Or check the download in your browser with the checksum calculator.