Bug 2227010

Summary: RFE: Prevent message content being logged at any level
Product: Red Hat Enterprise Linux 9 Reporter: Rehana <redakkan>
Component: rhcAssignee: Link Dupont <link>
Status: VERIFIED --- QA Contact: CSI Client Tools Bugs <csi-client-tools-bugs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 9.2CC: ahitacat, arpandey, cmarinea, qianzhan
Target Milestone: rcKeywords: FutureFeature, Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: rhc-0.2.4-1.el9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 2227141 (view as bug list) Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 2227141, 2227142    

Comment 8 qianzhan 2023-08-15 06:29:19 UTC
Final verification:

1. Provision RHEL-9.3.0-updates-20230814.d.26-BaseOS-x86_64 in Beaker.

2. The rhc version:

[root@ibm-x3650m4-01-vm-15 ~]# dnf install -y rhc-worker-playbook

[root@ibm-x3650m4-01-vm-15 ~]# rpm -qa | grep rhc
rhc-0.2.4-1.el9.x86_64
rhc-worker-playbook-0.1.8-6.el9.x86_64

3. Configure the log level to trace:

(1) [root@ibm-x3650m4-01-vm-15 ~]# cat /etc/rhc/config.toml 

# rhc global configuration settings

broker = ["wss://connect.cloud.redhat.com:443"]

cert-file = "/etc/pki/consumer/cert.pem"

key-file = "/etc/pki/consumer/key.pem"

log-level = "trace"

 
(2) [root@ibm-x3650m4-01-vm-15 ~]# systemctl cat rhcd

# /usr/lib/systemd/system/rhcd.service*

[Unit]

Description=Remote Host Configuration daemon

Documentation=https://github.com/redhatinsights/yggdrasil

After=network-online.target

Requires=network-online.target

[Service]

Type=simple

ExecStart=/usr/sbin/rhcd

[Install]

WantedBy=multi-user.target

# /etc/systemd/system/rhcd.service.d/override.conf*

[Service]

Environment=SYSTEMD_LOG_LEVEL=trace

 

4. [root@ibm-x3650m4-01-vm-15 ~]# rhc connect

Connecting ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com to Red Hat.

This might take a few seconds.

 

Username: insights-qa

Password: 

 

● Connected to Red Hat Subscription Management

● Connected to Red Hat Insights

● Activated the Remote Host Configuration daemon

● Enabled console.redhat.com services: compliance, remote configuration, remediations, insights

 

Successfully connected to Red Hat!

 

Manage your connected systems: https://red.ht/connector

 

STEP                       DURATION  

rhsm                       24.403s   

insights                   30.939s   

Remote Host Configuration  27ms      

 
5. [root@ibm-x3650m4-01-vm-15 ~]# journalctl -u rhcd | grep 'received message'

Aug 14 04:06:37 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:06:37 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message a44422fb-75ce-41f8-bc0b-bb21b1b18557

Aug 14 04:07:08 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:07:08 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message e75e114d-0080-4dc7-b4c0-292f8c4ca277

Aug 14 04:07:25 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:07:25 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message c9d233d0-3e65-47ff-a05f-2b3ea2883035

Aug 14 04:07:55 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:07:55 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 834c355e-9232-43d8-8870-598130b74717

Aug 14 04:08:24 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:08:24 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message e61cfc74-7781-4bbc-a966-5683154d7ceb

Aug 14 04:08:52 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:08:52 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 6d1669e8-fe10-4c66-8f19-84401c44acb1

Aug 14 04:09:08 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:09:08 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 3148ab01-f6a7-4d1f-87e9-7479c033fbd7

Aug 14 04:09:36 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:09:36 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 3a038750-6c9e-4c76-a105-6a31bf020eec

Aug 14 04:35:01 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:35:01 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message b5c8ee3a-5e64-4290-9433-58051d537264

Aug 14 04:35:29 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:35:29 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 8ced1505-5cf6-4f65-8b84-90909b4ec7dc

Aug 14 04:36:48 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:36:48 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 555a7862-f063-4b22-b18b-e2c92814104d

Aug 14 04:37:23 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:37:23 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message eeabd531-6aff-4cb4-9c0d-2c525a52a10c

Aug 14 04:37:51 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:37:51 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 97150198-f32e-4df0-a0fc-7ff026e8d029

Aug 14 04:38:25 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:38:25 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message cd39f34f-c086-4231-9b6f-ac9f0cd6a8fb

Aug 14 04:38:53 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:38:53 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message e6e6e721-c8c2-4ae4-a34c-430bdd81ecde

Aug 14 04:39:23 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:39:23 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message fbd0668e-062a-46b6-8cd1-023f5d8568c3

Aug 14 04:39:54 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:39:54 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 348cf653-9858-4fc6-a456-61cc626abf61

Aug 14 04:40:24 ibm-x3650m4-01-vm-15.ibm2.lab.eng.bos.redhat.com rhcd[18510]: [rhcd] 2023/08/14 04:40:24 /builddir/build/BUILD/rhc/yggdrasil-0.2.2/cmd/yggd/grpc.go:107: received message 5849487c-5505-436f-a531-743dad90dc06

 

 

From step 5, we can see that rhcd received messages, and only message IDs(not message content) are showed in the rhcd log. So move this bug from ON_QA to VERIFIED.