Bug 1912067

Summary: [RENAME] openssl qemu-ca conf files not handled well
Product: [oVirt] ovirt-engine Reporter: Yedidyah Bar David <didi>
Component: Tools.RenameAssignee: Yedidyah Bar David <didi>
Status: CLOSED DEFERRED QA Contact: Pavol Brilla <pbrilla>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.4.4CC: bugs, gdeolive, mperina
Target Milestone: ovirt-4.5.3Flags: sbonazzo: ovirt-4.5?
sbonazzo: devel_ack+
gdeolive: testing_ack+
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-09-06 09:15:21 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Integration RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Yedidyah Bar David 2021-01-03 07:41:54 UTC
Description of problem:

ovirt-engine-rename changes /etc/pki/ovirt-engine/qemu-cert.template to point at 'resource=ca-certificate' instead of keeping 'resource=qemu-ca-certificate'.

This is caused by the fix for bug 1875386.

Before bug 1875386, ovirt-engine-rename didn't change qemu-cert.template at all - it also didn't change the hostname to be the new name.

Also, it does not update /etc/pki/ovirt-engine/qemu-cert.conf at all, keeping it pointing at the old name. This was missed in the fix for bug 1875386.

Version-Release number of selected component (if applicable):
4.4.4.1

How reproducible:
Always

Steps to Reproduce:
1. Install and setup an engine with some FQDN
2. Run ovirt-engine-rename
3. grep authorityInfoAccess /etc/pki/ovirt-engine/qemu-cert.{conf,template}

Actual results:

qemu-cert.template points at:

caIssuers;URI:http://$NEW_FQDN:80/ovirt-engine/services/pki-resource?resource=ca-certificate&format=X509-PEM-CA

qemu-cert.conf points at:

caIssuers;URI:http://$OLD_FQDN:80/ovirt-engine/services/pki-resource?resource=qemu-ca-certificate&format=X509-PEM-CA

Expected results:

Both point at:

caIssuers;URI:http://$NEW_FQDN:80/ovirt-engine/services/pki-resource?resource=qemu-ca-certificate&format=X509-PEM-CA

Additional info:

Not sure how this affects use of certificates generated with the wrong conf. If it causes a problem, it should be fixed by reenrolling certificates for the host, after the engine is updated to a version that contains a fix to current bug.

Comment 1 Yedidyah Bar David 2022-05-17 06:11:55 UTC
*** Bug 2034570 has been marked as a duplicate of this bug. ***

Comment 2 Martin Perina 2022-09-06 09:15:21 UTC
Moved to https://github.com/oVirt/ovirt-engine/issues/638 due to resource limitation