TMAegisBeta
Mais regras para postgres

PostgreSQL

TMA-POSTGRES-1.3

Ensure systemd Service Files Are Enabled

BaixaNível 1Automatizadapostgres

Descrição

Confirm, and correct if necessary, the PostgreSQL systemd service is enabled. Passes when at least one postgresql* systemd service unit is enabled.

Como é verificado

Método de auditoria: Comando shell

shell
out=$(systemctl list-unit-files --type=service --no-legend 'postgresql*' 2>/dev/null) || exit 1; printf '%s\n' "$out" | awk '$2=="enabled"{e=1} END{print e?"enabled":"not-enabled"}'
Saída esperada
enabled

Como é corrigido

Método de correção: Orientação ou patch de infraestrutura

Enable the PostgreSQL unit for the default target, e.g. systemctl enable postgresql-18 (PGDG) or systemctl enable postgresql (Debian/Ubuntu), then confirm with systemctl is-enabled.

Propriedades

Sistemas operacionais
Qualquer
Tags
postgresdatabaseservice
Referência
CIS PostgreSQL 18 Benchmark v1.0.0 - 1.3 Ensure systemd Service Files Are Enabled

Verificar este host

Execute isto em uma máquina que você tenha permissão para auditar. A varredura é somente leitura.

shell
tmaegis scan --target postgres