Bug 1309435 - namedCertificates do not match the wild card certificate
namedCertificates do not match the wild card certificate
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Auth (Show other bugs)
3.1.0
x86_64 Linux
unspecified Severity medium
: ---
: ---
Assigned To: Jordan Liggitt
weiwei jiang
:
Depends On:
Blocks: 130
  Show dependency treegraph
 
Reported: 2016-02-17 14:45 EST by Kenny Woodson
Modified: 2016-10-30 18:55 EDT (History)
5 users (show)

See Also:
Fixed In Version: atomic-openshift-3.1.1.905-1.git.0.ef5902f.el7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-05-12 12:29:21 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Kenny Woodson 2016-02-17 14:45:11 EST
Description of problem:

When installing and configuring a cluster recently we added our SSL certificate to the master-config file and we added our configuration to the namedCertificates.  

master-config.yml:
  namedCertificates:
  - certFile: /etc/origin/master/named_certificates/star_tsi_openshift_com.crt
    keyFile: /etc/origin/master/named_certificates/tsi.key
    names:
    - "api.tsi.openshift.com"
    - "console.tsi.openshift.com"

We then proceeded to see this error:

Feb 17 13:17:07 ip-172-31-48-111.ec2.internal atomic-openshift-master-controllers[33594]: W0217 13:17:07.639989   33594 start_master.go:269] servingInfo.namedCertificates[0].names[0]: invalid value 'api.tsi.openshift.com', Details: the specified certificate does not have a CommonName or DNS subjectAltName that matches this name
Feb 17 13:17:07 ip-172-31-48-111.ec2.internal atomic-openshift-master-controllers[33594]: W0217 13:17:07.640112   33594 start_master.go:269] servingInfo.namedCertificates[0].names[1]: invalid value 'config.tsi.openshift.com', Details: the specified certificate does not have a CommonName or DNS subjectAltName that matches this name


The certificate is a wild card certificate:
Subject: C=US, ST=North Carolina, L=Raleigh, O=Red Hat Inc.,CN=*.tsi.openshift.com


SLL command:
openssl x509 -in /etc/origin/master/named_certificates/star_tsi_openshift_com.crt -text -noout | grep -A 1 "Subject Alternative Name"
            X509v3 Subject Alternative Name:
                DNS:*.tsi.openshift.com, DNS:tsi.openshift.com





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

How reproducible:
I'm not sure but we saw this on a fresh create and using the openshift-ansible byo playbooks.

Steps to Reproduce:
1. Set the values in /etc/origin/master-config.yml correctly. (those mentioned above)
2.  Attempt to start the master service. 
systemctl restart atomic-openshift-master-controllers.service
3. Look for the error message in the journal.  
journalctl -lu atomic-openshift-master-controllers

Actual results:
We are seeing that the wild card does not match the names given.

Expected results:
The names should match and we should not see the error.

Additional info:
Comment 1 Jordan Liggitt 2016-02-17 14:52:14 EST
Fixed in https://github.com/openshift/origin/pull/7399
Comment 2 Jordan Liggitt 2016-02-19 10:09:50 EST
Hostname verification merged upstream in https://github.com/openshift/origin/pull/7399
Comment 3 weiwei jiang 2016-02-23 04:59:10 EST
Checked with devenv-rhel7_3509 and 
openshift v3.1.1.905
kubernetes v1.2.0-alpha.7-703-gbc4550d
etcd 2.2.5

The bug can not be reproduced.
Comment 5 errata-xmlrpc 2016-05-12 12:29:21 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2016:1064

Note You need to log in before you can comment on or make changes to this bug.