Skip to content

Update testbed CA and certificates - #1404

Merged
berendt merged 4 commits into
mainfrom
update-testbed-certs
Jun 22, 2023
Merged

berendt merged 4 commits into
mainfrom
update-testbed-certs

Conversation

@osfrickler

Copy link
Copy Markdown
Member

We need to set subject_alt_name_critical: true for the manager and wildcard certificates, but not for the CA. Update the ownca doc to mention all the locations that need to be updated when creating new certificates.

Closes: #1402
Signed-off-by: Dr. Jens Harbott [email protected]

@osfrickler

Copy link
Copy Markdown
Member Author

@reqa the CI now fails at https://github.com/osism/testbed/blame/main/environments/custom/playbook-keycloak-oidc-client-config.yml , the error in keycloak looks like:

10:25:24,883 WARN  [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (default task-1) SQL Error: 0, SQLState: 22001                                                                          
10:25:24,884 ERROR [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (default task-1) ERROR: value too long for type character varying(4000)                                                 
10:25:24,899 ERROR [org.hibernate.internal.ExceptionMapperStandardImpl] (default task-1) HHH000346: Error during managed flush [org.hibernate.exception.DataException: could not execute state
ment]

Can you please check what might be the issue here? Or maybe give it a test in your own environment?

@reqa

reqa commented Nov 28, 2022

Copy link
Copy Markdown
Contributor

Doesn't seem related to SSL certificates, but something like this between Keycloak and its SQL backend.

osfrickler and others added 3 commits June 19, 2023 20:04
We need to set `subject_alt_name_critical: true` for the manager and
wildcard certificates, but not for the CA. Update the ownca doc to
mention all the locations that need to be updated when creating new
certificates.

Closes: #1402
Signed-off-by: Dr. Jens Harbott <[email protected]>
Ok, I've reviewed the commit proposed for #1402 and I think
the proposed changes to the following files need to be avoided:

* environments/kolla/configuration.yml
* a/environments/kolla/files/overlays/keystone/federation/oidc/kD9RIBcPiCOVO8wOM2VbZD5XnpgSkf-tWdSmhurxmJo.pem
* b/environments/kolla/files/overlays/keystone/federation/oidc/keycloak-cert.pem

The strangely named pem file is

1. not the SSL certificate, but a Keycloak/OIDC specific signing
   certificate (JWKS)
2. referenced by the parameter OIDCOAuthVerifyCertFiles in
   wsgi-keycloak.conf

Maybe we can and should get rid of that file by making use
of OIDCOAuthVerifyJwksUri in wsgi-keycloak.conf but that is an
entirely different issue.

Signed-off-by: Arvid Requate <[email protected]>
Until now keycloak/cert.crt and the `traefik_certificates`
in secrets.yml contained the wildcard certificate.

The proposed "Update testbed CA and certificates" commit
proposed to change that to use the manager certificate instead
and explicitly include "DNS:keycloak.testbed.osism.xyz" as additional
subject_alt_name.

This commit proposes to continue using the wildcard certificate:
There's the related proposal that Keycloak shall be moved away
from the manager node to K3S, so maybe we should not attach more
manager related strings to Keycloak currently.

Signed-off-by: Arvid Requate <[email protected]>
@berendt
berendt force-pushed the update-testbed-certs branch from fb78bda to 87c6e06 Compare June 19, 2023 18:04
@berendt
berendt force-pushed the update-testbed-certs branch from 87c6e06 to 58985c6 Compare June 19, 2023 19:56
@berendt
berendt merged commit f2ac67b into main Jun 22, 2023
@berendt
berendt deleted the update-testbed-certs branch June 22, 2023 09:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update wildcard and manager certificate

3 participants