dogtagpki / pki

The Dogtag Certificate System is an enterprise-class Certificate Authority (CA) which supports all aspects of certificate lifecycle management, including key archival, OCSP and smartcard management.
https://www.dogtagpki.org
GNU General Public License v2.0
361 stars 134 forks source link

Improve error reporting when the imported certs are invalid #2456

Open pki-bot opened 3 years ago

pki-bot commented 3 years ago

This issue was migrated from Pagure Issue #2336. Originally filed by spoore (@spoore1) on 2016-05-20 18:34:04:


I am seeing a failure both when using --setup-ca in ipa-replica-install and running ipa-ca-install separately when --setup-ca not used.

From an ipa-ca-install:

Configuring certificate server (pki-tomcatd). Estimated time: 3 minutes 30 seconds [1/22]: creating certificate server user [2/22]: configuring certificate server instance ipa.ipaserver.install.cainstance.CAInstance: CRITICAL Failed to configure CA instance: Command /usr/sbin/pkispawn' '-s' 'CA' '-f' '/tmp/tmp4raVhy returned non-zero exit status 1 ipa.ipaserver.install.cainstance.CAInstance: CRITICAL See the installation logs and the following files/directories for more information: ipa.ipaserver.install.cainstance.CAInstance: CRITICAL /var/log/pki-ca-install.log ipa.ipaserver.install.cainstance.CAInstance: CRITICAL /var/log/pki/pki-tomcat [error] RuntimeError: CA configuration failed.

Your system may be partly configured. Run /usr/sbin/ipa-server-install --uninstall to clean up.

CA configuration failed.

Then at the end of the /var/log/pki/pki-tomcat/ca/debug, I see this:

[01/Apr/2016:20:49:37]http-bio-8443-exec-3: SystemConfigService: clone does not have all the certificates. [01/Apr/2016:20:49:37]http-bio-8443-exec-3: Clone does not have all the required certificates

Steps to Reproduce:

1.  Install IPA master
2.  Install IPA replica
3.  Install CA on replica using:
ipa-ca-install -p Password -w Password /var/lib/ipa/replica-file.gpg

Problem was also seen with 2 steps:
1.  Install IPA master
2.  Install IPA replica with CA
include --setup-ca in ipa-replica-install command.

Actual results:

Fails as mentioned above.

Expected results:

No failure and CA properly installed.

Additional info:

While this particular problem might be caused by environment issue, invalid certificate could happen due to various reasons (e.g. expired certificate, future certificate validity, missing extension). To help troubleshooting the installation code should be fixed to show which specific certificate is missing/invalid.
pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2016-05-23 23:21:04

Per CS/DS Meeting of 05/23/2016: 10.4

pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2016-12-01 20:32:27

Per Offline Triage of 11/30/2016-12/01/2016: 10.4 - major

pki-bot commented 3 years ago

Comment from spoore (@spoore1) at 2017-02-27 14:01:42

Metadata Update from @spoore1:

pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2017-03-03 20:57:54

Metadata Update from @mharmsen:

pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2017-04-07 16:43:53

Metadata Update from @mharmsen:

pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2017-09-25 17:07:02

Metadata Update from @mharmsen:

pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2017-10-25 17:51:54

[20171025] - Offline Triage ==> 10.6

pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2017-10-25 17:51:55

Metadata Update from @mharmsen:

pki-bot commented 3 years ago

Comment from mharmsen (@mharmsen) at 2018-04-13 18:54:05

Per 10.5.x/10.6 Triage: 10.6

mharmsen: improve error reporting