Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
DescriptionFlorence Blanc-Renaud
2021-06-17 06:27:06 UTC
Cloned from upstream: https://pagure.io/freeipa/issue/8880
### Issue
In a CA less setup, if the CA certificate subject contains non-ASCII characters, ipa-server-install fails with a UnicodeDecodeError.
#### Steps to Reproduce
1. Create a CA with subject CN=CA,O=España
2. With this CA, create http and dirsrv certificates CN=server.ipa.test,O=España
3. install the server with ipa-server-install --http-cert-file .. --dirsrv-cert-file .. --ca-cert-file
#### Actual behavior
ipa-server-install fails when configuring SSL for HTTPd:
```
Configuring the web interface (httpd)
[1/20]: stopping httpd
[2/20]: backing up ssl.conf
[3/20]: disabling nss.conf
[4/20]: configuring mod_ssl certificate paths
[5/20]: setting mod_ssl protocol list
[6/20]: configuring mod_ssl log directory
[7/20]: disabling mod_ssl OCSP
[8/20]: adding URL rewriting rules
[9/20]: configuring httpd
[10/20]: setting up httpd keytab
[11/20]: configuring Gssproxy
[12/20]: setting up ssl
[error] UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd1 in position 67: invalid continuation byte
'utf-8' codec can't decode byte 0xd1 in position 67: invalid continuation byte
The ipa-server-install command failed. See /var/log/ipaserver-install.log for more information
```
#### Expected behavior
The installation should succeed
#### Version/Release/Distribution
freeipa-server-4.9.3-4.fc34.x86_64
freeipa-client-4.9.3-4.fc34.x86_64
389-ds-base-2.0.5-1.fc34.x86_64
pki-ca-10.10.5-6.fc34.noarch
krb5-server-1.19.1-3.fc34.x86_64
#### Additional info:
Traceback:
```
2021-06-09T16:43:35Z DEBUG Traceback (most recent call last):
File "/usr/lib/python3.9/site-packages/ipaserver/install/service.py", line 635, in start_creation
run_step(full_msg, method)
File "/usr/lib/python3.9/site-packages/ipaserver/install/service.py", line 621, in run_step
method()
File "/usr/lib/python3.9/site-packages/ipaserver/install/httpinstance.py", line 331, in __setup_ssl
p12_certs, p12_priv_keys = certs.pkcs12_to_certkeys(
File "/usr/lib/python3.9/site-packages/ipaserver/install/certs.py", line 106, in pkcs12_to_certkeys
pems = ipautil.run(args, capture_output=True).raw_output
File "/usr/lib/python3.9/site-packages/ipapython/ipautil.py", line 585, in run
output = stdout.decode(encoding)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd1 in position 67: invalid continuation byte
```
Comment 1Florence Blanc-Renaud
2021-06-17 06:28:15 UTC
Comment 2Florence Blanc-Renaud
2021-06-17 06:28:34 UTC
Fixed upstream:
master:
fb74866 CA-less install: non-ASCII chars in CA cert subject
0faddc9 ipatests: use non-ascii chars in CA-less install
ipa-4-9:
7b278b6 CA-less install: non-ASCII chars in CA cert subject
4b040e1 ipatests: use non-ascii chars in CA-less install