STIGQter STIGQter: STIG Summary: IBM DB2 V10.5 LUW Security Technical Implementation Guide Version: 1 Release: 4 Benchmark Date: 25 Oct 2019:

DB2 must produce audit records of its enforcement of access restrictions associated with changes to the configuration of DB2 or database(s).

DISA Rule

SV-89267r1_rule

Vulnerability Number

V-74593

Group Title

SRG-APP-000381-DB-000361

Rule Version

DB2X-00-008200

Severity

CAT II

CCI(s)

Weight

10

Fix Recommendation

Run the following command to set the auditing at the instance level:

$db2audit configure scope sysadmin status both error type audit

Run the following command to set the auditing at the database level:
DB2> CREATE AUDIT POLICY <DB audit policy name> CATEGORIES SYSADMIN STATUS BOTH, CONTEXT STATUS BOTH ERROR TYPE AUDIT

Run the following command if the auditing policy exists but does not include the sysadmin category:
DB2> ALTER AUDIT POLICY <DB audit policy name> SYSADMIN STATUS BOTH, CONTEXT STATUS BOTH ERROR TYPE AUDIT

If CREATE was used above, apply the policy created above to the database:
DB2> AUDIT DATABASE USING POLICY <DB audit policy name>

Note: See the following page for knowledgebase information regarding the ALTER AUDIT POLICY:
http://www.ibm.com/support/knowledgecenter/SSEPGG_10.5.0/com.ibm.db2.luw.sql.ref.doc/doc/r0050608.html?lang=en

Check Contents

To audit changes in configuration, the SYSADMIN category needs to be audited at both the instance level and the database level.

Run the following command to ensure that the SYSADMIN category is being audited at the instance level:

$db2audit describe

If Log system administrator events is not set to “Both”, this is a finding.

Run the following SQL statement to ensure that an audit policy exists at the database level:
DB2> SELECT AUDITPOLICYNAME, AUDITPOLICYID
FROM SYSCAT.AUDITUSE
WHERE OBJECTTYPE = ' '

If no rows are returned, this is a finding.

For the audit policy returned in the statement above, run the following SQL statement to confirm that the SYSADMIN category is part of that policy and the ERROR TYPE='A':
DB2> SELECT AUDITPOLICYNAME, SYSADMINSTATUS, CONTEXTSTATUS, ERRORTYPE AS ERRORTYPE
FROM SYSCAT.AUDITPOLICIES
WHERE AUDITPOLICYID = <audit policy ID>

If the values for SYSADMINSTATUS and CONTEXTSTATUS are not 'B' (Both) or ERRORTYPE is not 'A' (Audit), this is a finding.

Vulnerability Number

V-74593

Documentable

False

Rule Version

DB2X-00-008200

Severity Override Guidance

To audit changes in configuration, the SYSADMIN category needs to be audited at both the instance level and the database level.

Run the following command to ensure that the SYSADMIN category is being audited at the instance level:

$db2audit describe

If Log system administrator events is not set to “Both”, this is a finding.

Run the following SQL statement to ensure that an audit policy exists at the database level:
DB2> SELECT AUDITPOLICYNAME, AUDITPOLICYID
FROM SYSCAT.AUDITUSE
WHERE OBJECTTYPE = ' '

If no rows are returned, this is a finding.

For the audit policy returned in the statement above, run the following SQL statement to confirm that the SYSADMIN category is part of that policy and the ERROR TYPE='A':
DB2> SELECT AUDITPOLICYNAME, SYSADMINSTATUS, CONTEXTSTATUS, ERRORTYPE AS ERRORTYPE
FROM SYSCAT.AUDITPOLICIES
WHERE AUDITPOLICYID = <audit policy ID>

If the values for SYSADMINSTATUS and CONTEXTSTATUS are not 'B' (Both) or ERRORTYPE is not 'A' (Audit), this is a finding.

Check Content Reference

M

Target Key

3161

Comments