Summary
This document will guide you through the steps to enable multi-factor authentication and Single-Sign On for the open source container application platform Openshift (https://www.openshift.com/) using OpenID Connect.
System Requirements
- PhenixID Authentication Server 4.0 or higher
- Openshift administration rights
Instruction
Overview
This document will guide you through the steps to enable multi-factor authentication and Single-Sign on for Red Hat Openshift.
PhenixID Authentication Services acting as OpenID Connect Provider
- Login to Configuration Manager.
- Scenarios->OIDC
- Add a new relying party:
– client_id = openshift
– client_password = <create a password and set>
– Allowed redirect uri:s = <ask the OpenShift admin which value to use> - Create a new OpenID Connect provider by selecting the desired authentication method. Follow the scenario guidelines for values.
Use the Authorization Code Flow.
Allow openshift as an allowed RP to use the OP. - Once done, click Execution flow
- Expand token endpoint
- Expand GenerateJwtTokenVavle
- On the token attributes part, add a new name-value pair:
name = name
value = {{session.givenName}} {{session.sn}} - Save changes.
- Click Add valve
- Select PropertyAddValve
- Enter name = token_type and value = Bearer. Make sure the valve is placed last in the execution flow.
- Save the changes
- Click on the OpenID Connect Provider and then General
- Click View OP Discovery
- Copy the OP discovery URL and send it, together with client_id and client_secret, to the OpenShift administrator
Configure OpenShift
- Login, as an administrator, to OpenShift
- Follow this guide to add a new authentication provider: https://docs.openshift.com/container-platform/4.6/authentication/identity_providers/configuring-oidc-identity-provider.html#identity-provider-oidc-CR_configuring-oidc-identity-provider
- Set these values for the new provider: identityProviders:
– mappingMethod: claim
name: PhenixID
openID:
claims:
email:
– email
name:
– name
preferredUsername:
– sub
clientID: openshift
clientSecret:
name: openid-secret
issuer: ‘REPLACE_WITH_THE_OP_ISSUER_VALUE’
type: OpenID
Replace REPLACE_WITH_THE_OP_ISSUER_VALUE with the correct issuer value which can be found at the OIDC OP Discovery. Set clientID and clientSecret to the values distributed from the PhenixID Authentication Services administrator.
- Save the config. Restart if needed.
Test
- Browse to OpenShift
- Click on PhenixID for authentication
- Your browser should be redirected to PhenixID Authentication Services for authentication.
- Authenticate
- You should now be redirected back to OpenShift.
- You should now be logged in to OpenShift.
DISCLAIMER
Information provided in this document is for your information only. PhenixID makes no explicit or implied claims to the validity of this information. Any trademarks referenced in this document are the property of their respective owners.The origin of this information may be internal or external to PhenixID. PhenixID makes all reasonable efforts to verify this information.
PhenixID - support.phenixid.se