Vulnerability Discussion
Protecting audit data also includes identifying and protecting the tools used to view and manipulate log data. Therefore, protecting audit tools is necessary to prevent unauthorized operation on audit data.
Applications providing tools to interface with audit data will leverage user permissions and roles identifying the user accessing the tools and the corresponding rights the user enjoys in order to make access decisions regarding the access to audit tools.
Audit tools include, but are not limited to, vendor-provided and open source audit tools needed to successfully view and manipulate audit information system activity and records. Audit tools include custom queries and report generators.
Satisfies: SRG-APP-000121-CTR-000255, SRG-APP-000122-CTR-000260, SRG-APP-000123-CTR-000265
Check
List the users and groups who have permission to view the cluster logging configuration by executing the following two commands:
oc policy who-can view ClusterLogging -n openshift-logging
oc policy who-can view ClusterLoggingForwarder -n openshift-logging
Review the list of users and groups who have view access to the cluster logging resources. If any user or group listed must not have access to view the cluster logging resources, this is a finding.
Fix
Remove view permissions from any unauthorized user or group by performing one or more of the following commands.
Remove role from user by executing the following:
oc adm policy remove-role-from-user -n openshift-logging
Remove role from group by executing the following:
oc adm policy remove-role-from-group -n openshift-logging
Remove cluster role from user by executing the following:
oc adm policy remove-cluster-role-from-user -n openshift-logging
Remove cluster role from group by executing the following:
oc adm policy remove-cluster-role-from-group -n openshift-logging
Note: ROLE/CLUSTER_ROLE is the role granting user view permission to resources in openshift-logging namespace.