#5902 CA installed on replica is always marked as renewal master
Closed: Fixed None Opened 4 years ago by mbabinsk.

When doing installation of clone CA on a replica, the {{{cn=CA,cn=$FQDN,cn=masters,cn=ipa,cn=etc,$SUFFIX}} entry of freshly installed master is always marked as 'caRenewalMaster'. This means that there are multiple CA renewal masters in topology which can cause great problems when renewing certificates nearing expiration.

Steps to reproduce:

1.) install IPA master

2.) create either domain level 0 or 1 replica w/ CA, or do a standalone CA install on the replica

3.) Search for 'ipaConfigString=caRenewalMaster' attribute:

$ ldapsearch -Y GSSAPI -b 'cn=masters,cn=ipa,cn=etc,$SUFFIX' '(ipaConfigString=caRenewalMaster)'

Expected result:

the search returns one entry corresponding to the CA renewal:

SASL/GSSAPI authentication started
SASL username: admin@IPA.TEST
SASL SSF: 56
SASL data security layer installed.
# extended LDIF
#
# LDAPv3
# base <cn=masters,cn=ipa,cn=etc,dc=ipa,dc=test> with scope subtree
# filter: (ipaConfigString=caRenewalMaster)
# requesting: ALL
#

...

# numEntries: 1

Actual result:

After installing CA replica two entries with 'ipaConfigString=caRenewalMaster' are present.

SASL/GSSAPI authentication started
SASL username: admin@IPA.TEST
SASL SSF: 56
SASL data security layer installed.
# extended LDIF
#
# LDAPv3
# base <cn=masters,cn=ipa,cn=etc,dc=ipa,dc=test> with scope subtree
# filter: (ipaConfigString=caRenewalMaster)
# requesting: ALL
#

...

# numEntries: 2

This happens due to the code unconditionally setting {{{ipaConfigString=caRenewalMaster}}} on new CA instances on two places:

here during domain level 1 replica install (ipa-4-3 and master only):

https://git.fedorahosted.org/cgit/freeipa.git/tree/ipaserver/install/cainstance.py#n1291

here during CA install regardless of domain level (ipa-4-2, ipa-4-3, and master):

https://git.fedorahosted.org/cgit/freeipa.git/tree/ipaserver/install/ca.py#n191

Reproduced on CentOS 7 using ipa-server-4.2.0-15.0.1.el7.centos.6.1.x86_64 and also on Fedora 23 using freeipa-server-4.3.1-1.fc23.x86_64 in both domain levels (see links to the code above).


master:

  • dea924a replica install: do not set CA renewal master flag

ipa-4-2:

  • 9d39d5e replica install: do not set CA renewal master flag

ipa-4-3:

  • 1b427d3 replica install: do not set CA renewal master flag

Metadata Update from @mbabinsk:
- Issue assigned to jcholast
- Issue set to the milestone: FreeIPA 4.2.5

3 years ago

Login to comment on this ticket.

Metadata