Access Rules Configuration via PgSmart Web
Once a PostgreSQL instance has been created (Instance Initialization), the database engine provides mechanisms to restrict access to data. This is the first level of security for the PostgreSQL instance, determining whether a connection can be opened or not.
Client authentication is managed through the pg_hba.conf
configuration file, located in the cluster’s data directory (hba stands for Host-Based Authentication). A default pg_hba.conf
file is created when the PostgreSQL instance is initialized.
note
When configuring Access Rules, you can define the connection type, target database(s), user(s) or group(s), authorized subnet or host, and the authentication method.
Prerequisites
- Instance initialized
- Instructions
- Add
- Edit
- Duplicate
- Delete
- From the top navigation dropdown, select the
Environment
. - In the left sidebar menu, select
Banco de Dados
. If any instances are registered, acard
will be displayed for each instance in the selected environment. - Select the instance where you want to configure access rules.
- Click the
Regras de Acesso
tab.

Figure 1 - Select Access Rules option
Add an Access Rule
- To add a new
Access Rule
: 1.1. ClickIncluir
. 1.2. Specify the access rule type. 1.3. Enter the target database(s) (comma-separated list or "all"). 1.4. Enter the user(s) or group(s) (comma-separated list or "all"). 1.5. Select the desired authentication method. 1.6. ClickSalvar
.

Figure 2a - Add Access Rule - Options

Figure 2b - Add Access Rule
Edit an Access Rule
- To edit an existing
Access Rule
: 1.1. Click the pencil icon ✏ to edit. 1.2. Modify the desired fields. 1.3. ClickSalvar
.

Figure 3 - Edit Access Rule
Duplicate an Access Rule
- To duplicate an
Access Rule
: 1.1. Click the duplicate icon ⧉.

Figure 4 - Add/Edit Access Rule
Delete an Access Rule
- To delete an
Access Rule
: 1.1. Click the trash icon 🗑.

Figure 5 - Delete Access Rule