From PostgreSQL 9.x Security Technical Implementation Guide
Part of SRG-APP-000267-DB-000163
Associated with: CCI-001314
If PostgreSQL provides too much information in error logs and administrative messages to the screen, this could lead to compromise. The structure and content of error messages need to be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.
Note: The following instructions use the PGDATA environment variable. See supplementary content APPENDIX-F for instructions on configuring PGDATA.
Check PostgreSQL settings and custom database code to determine if detailed error messages are ever displayed to unauthorized individuals.
To check the level of detail for errors exposed to clients, as the database administrator (shown here as "postgres"), run the following:
$ sudo su - postgres
$ grep "client_min_messages" ${PGDATA?}/postgresql.conf
If client_min_messages is set to LOG or DEBUG, this is a finding.
If detailed error messages are displayed to individuals not authorized to view them, this is a finding.
#### stderr Logging
Logs may contain detailed information and should only be accessible by the database owner.
As the database administrator, verify the following settings of logs in the postgresql.conf file.
Note: Consult the organization's documentation on acceptable log privileges
$ sudo su - postgres
$ grep log_directory ${PGDATA?}/postgresql.conf
$ grep log_file_mode ${PGDATA?}/postgresql.conf
Next, verify the log files have the set configurations.
Note: Use location of logs from log_directory.
$ ls -l
Note: The following instructions use the PGDATA environment variable. See supplementary content APPENDIX-F for instructions on configuring PGDATA. To set the level of detail for errors messages exposed to clients, as the database administrator (shown here as "postgres"), run the following commands: $ sudo su - postgres $ vi ${PGDATA?}/postgresql.conf client_min_messages = notice
Lavender hyperlinks in small type off to the right (of CSS
class id
, if you view the page source) point to
globally unique URIs for each document and item. Copy the
link location and paste anywhere you need to talk
unambiguously about these things.
You can obtain data about documents and items in other
formats. Simply provide an HTTP header Accept:
text/turtle
or
Accept: application/rdf+xml
.
Powered by sagemincer