SV-261927r1050788_rule
V-261927
SRG-APP-000389-DB-000372
CD16-00-008100
CAT II
10
Modify and/or configure PostgreSQL and related applications and tools so that users are always required to reauthenticate when changing role or escalating privileges.
To make a single user reauthenticate, the following must be present:
SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE user='<username>'
To make all users reauthenticate, the following must be present:
SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE user LIKE '%'
Determine all situations where a user must reauthenticate. Check if the mechanisms that handle such situations use the following SQL:
To make a single user reauthenticate, the following must be present:
SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE user='<username>'
To make all users reauthenticate, run the following:
SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE user LIKE '%'
If the provided SQL does not force reauthentication, this is a finding.
V-261927
False
CD16-00-008100
Determine all situations where a user must reauthenticate. Check if the mechanisms that handle such situations use the following SQL:
To make a single user reauthenticate, the following must be present:
SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE user='<username>'
To make all users reauthenticate, run the following:
SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE user LIKE '%'
If the provided SQL does not force reauthentication, this is a finding.
M
5598