Bug 2017773

Summary: (release-4.9) obfuscate identity provider attributes in collected authentication.operator.openshift.io resource
Product: OpenShift Container Platform Reporter: Tomas Remes <tremes>
Component: Insights OperatorAssignee: Tomas Remes <tremes>
Status: CLOSED ERRATA QA Contact: Joao Fula <jfula>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.9CC: aos-bugs, dmisharo, inecas, mklika, tremes
Target Milestone: ---   
Target Release: 4.9.z   
Hardware: Unspecified   
OS: Unspecified   
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 2017752 Environment:
Last Closed: 2021-11-22 21:47:05 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On: 2017752    
Bug Blocks: 2021572    

Description Tomas Remes 2021-10-27 12:10:18 UTC
+++ This bug was initially created as a clone of Bug #2017752 +++

The gathered resource (in config/clusteroperator/operator.openshift.io/authentication/cluster.json) can include some potentially sensitive data about identity providers. Examples are LDAP domain names, client IDs, issuers domain and similar.

This BZ is to obfuscate (replace with "X" characters) these attributes by default.

Comment 2 Joao Fula 2021-11-16 08:58:19 UTC
Verified on 4.9.0-0.nightly-2021-11-15-194804

Verification steps:
1. Enable Github identity provider https://docs.openshift.com/container-platform/4.9/authentication/identity_providers/configuring-github-identity-provider.html
2. Restart the Insights Operator
3. Wait until an insights archive will be created
4. Download the archive
5. Check the content of config/clusteroperator/operator.openshift.io/authentication/cluster.json

"clientID" field is obfuscated.

Comment 5 errata-xmlrpc 2021-11-22 21:47:05 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (OpenShift Container Platform 4.9.8 bug fix update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.