Ce contenu n'est pas disponible dans la langue sélectionnée.
4.3. Replacing SHA-1 Certificates with SHA-256 Certificates
Red Hat Virtualization 4.1 uses SHA-256 signatures, which provide a more secure way to sign SSL certificates than SHA-1. Newly installed 4.1 systems do not require any special steps to enable Red Hat Virtualization's public key infrastructure (PKI) to use SHA-256 signatures. However, for upgraded systems one of the following is recommended:
- Option 1: Prevent warning messages from appearing in your browser when connecting to the Administration Portal. These warnings may either appear as pop-up windows or in the browser's Web Console window. This option is not required if you already replaced the Red Hat Virtualization Manager's Apache SSL certificate after the upgrade. However, if the certificate was signed with SHA-1, you should replace it with an SHA-256 certificate. For more details see Replacing the Red Hat Virtualization Manager SSL Certificate in the Administration Guide.
- Option 2: Replace the SHA-1 certificates throughout the system with SHA-256 certificates.
Procedure 4.3. Preventing Warning Messages from Appearing in the Browser
- Log in to the Manager machine as the root user.
- Check whether
/etc/pki/ovirt-engine/openssl.confincludes the linedefault_md = sha256:If it still includescat /etc/pki/ovirt-engine/openssl.conf
# cat /etc/pki/ovirt-engine/openssl.confCopy to Clipboard Copied! Toggle word wrap Toggle overflow default_md = sha1, back up the existing configuration and change the default tosha256:cp -p /etc/pki/ovirt-engine/openssl.conf /etc/pki/ovirt-engine/openssl.conf."$(date +"%Y%m%d%H%M%S")" sed -i 's/^default_md = sha1/default_md = sha256/' /etc/pki/ovirt-engine/openssl.conf
# cp -p /etc/pki/ovirt-engine/openssl.conf /etc/pki/ovirt-engine/openssl.conf."$(date +"%Y%m%d%H%M%S")" # sed -i 's/^default_md = sha1/default_md = sha256/' /etc/pki/ovirt-engine/openssl.confCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Define the certificate that should be re-signed:
names="apache"
# names="apache"Copy to Clipboard Copied! Toggle word wrap Toggle overflow - For self-hosted engine environments, log in to one of the self-hosted engine nodes and enable global maintenance:
hosted-engine --set-maintenance --mode=global
# hosted-engine --set-maintenance --mode=globalCopy to Clipboard Copied! Toggle word wrap Toggle overflow - On the Manager, re-sign the Apache certificate:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Restart the
httpdservice:systemctl restart httpd
# systemctl restart httpdCopy to Clipboard Copied! Toggle word wrap Toggle overflow - For self-hosted engine environments, log in to one of the self-hosted engine nodes and disable global maintenance:
hosted-engine --set-maintenance --mode=none
# hosted-engine --set-maintenance --mode=noneCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Connect to the Administration Portal to confirm that the warning no longer appears.
- If you previously imported a CA or https certificate into the browser, find the certificate(s), remove them from the browser, and reimport the new CA certificate. Install the certificate authority according to the instructions provided by your browser. To get the certificate authority's certificate, navigate to
http://your-manager-fqdn/ovirt-engine/services/pki-resource?resource=ca-certificate&format=X509-PEM-CA, replacing your-manager-fqdn with the fully qualified domain name (FQDN).
Procedure 4.4. Replacing All Signed Certificates with SHA-256
- Log in to the Manager machine as the root user.
- Check whether
/etc/pki/ovirt-engine/openssl.confincludes the linedefault_md = sha256:If it still includescat /etc/pki/ovirt-engine/openssl.conf
# cat /etc/pki/ovirt-engine/openssl.confCopy to Clipboard Copied! Toggle word wrap Toggle overflow default_md = sha1, back up the existing configuration and change the default tosha256:cp -p /etc/pki/ovirt-engine/openssl.conf /etc/pki/ovirt-engine/openssl.conf."$(date +"%Y%m%d%H%M%S")" sed -i 's/^default_md = sha1/default_md = sha256/' /etc/pki/ovirt-engine/openssl.conf
# cp -p /etc/pki/ovirt-engine/openssl.conf /etc/pki/ovirt-engine/openssl.conf."$(date +"%Y%m%d%H%M%S")" # sed -i 's/^default_md = sha1/default_md = sha256/' /etc/pki/ovirt-engine/openssl.confCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Re-sign the CA certificate by backing it up and creating a new certificate in
ca.pem.new:cp -p /etc/pki/ovirt-engine/private/ca.pem /etc/pki/ovirt-engine/private/ca.pem."$(date +"%Y%m%d%H%M%S")" openssl x509 -signkey /etc/pki/ovirt-engine/private/ca.pem -in /etc/pki/ovirt-engine/ca.pem -out /etc/pki/ovirt-engine/ca.pem.new -days 3650 -sha256
# cp -p /etc/pki/ovirt-engine/private/ca.pem /etc/pki/ovirt-engine/private/ca.pem."$(date +"%Y%m%d%H%M%S")" # openssl x509 -signkey /etc/pki/ovirt-engine/private/ca.pem -in /etc/pki/ovirt-engine/ca.pem -out /etc/pki/ovirt-engine/ca.pem.new -days 3650 -sha256Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Replace the existing certificate with the new certificate:
mv /etc/pki/ovirt-engine/ca.pem.new /etc/pki/ovirt-engine/ca.pem
# mv /etc/pki/ovirt-engine/ca.pem.new /etc/pki/ovirt-engine/ca.pemCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Define the certificates that should be re-signed:If you replaced the Red Hat Virtualization Manager SSL Certificate after the upgrade, run the following instead:
names="engine apache websocket-proxy jboss imageio-proxy"
# names="engine apache websocket-proxy jboss imageio-proxy"Copy to Clipboard Copied! Toggle word wrap Toggle overflow For more details see Replacing the Red Hat Virtualization Manager SSL Certificate in the Administration Guide.names="engine websocket-proxy jboss imageio-proxy"
# names="engine websocket-proxy jboss imageio-proxy"Copy to Clipboard Copied! Toggle word wrap Toggle overflow - For self-hosted engine environments, log in to one of the self-hosted engine nodes and enable global maintenance:
hosted-engine --set-maintenance --mode=global
# hosted-engine --set-maintenance --mode=globalCopy to Clipboard Copied! Toggle word wrap Toggle overflow - On the Manager, re-sign the certificates:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Restart the following services:
systemctl restart httpd systemctl restart ovirt-engine systemctl restart ovirt-websocket-proxy systemctl restart ovirt-imageio-proxy
# systemctl restart httpd # systemctl restart ovirt-engine # systemctl restart ovirt-websocket-proxy # systemctl restart ovirt-imageio-proxyCopy to Clipboard Copied! Toggle word wrap Toggle overflow - For self-hosted engine environments, log in to one of the self-hosted engine nodes and disable global maintenance:
hosted-engine --set-maintenance --mode=none
# hosted-engine --set-maintenance --mode=noneCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Connect to the Administration Portal to confirm that the warning no longer appears.
- If you previously imported a CA or https certificate into the browser, find the certificate(s), remove them from the browser, and reimport the new CA certificate. Install the certificate authority according to the instructions provided by your browser. To get the certificate authority's certificate, navigate to
http://your-manager-fqdn/ovirt-engine/services/pki-resource?resource=ca-certificate&format=X509-PEM-CA, replacing your-manager-fqdn with the fully qualified domain name (FQDN). - Enroll the certificates on the hosts. Repeat the following procedure for each host.
- In the Administration Portal, click the Hosts tab.
- Select the host, and click
. - Once the host is in maintenance mode, click
. - Click
.