External Authentication Providers

Multiple external authentication providers can be defined using [provider.x] sections:

[provider.1]
type = oidc
                            # Provider type, currently only oidc is available
name = OIDC Example
                            # Display name
issuer = example
                            # issuer of the tokens. Can be "google", "microsoft"
                            # or an arbitrary string for custom identity
                            # providers
icon = url('data:image/svg+xml;base64,...')
                            # Optional display icon. Can be either a remote or
                            # a data URL. If omitted, a default icon is used
                            # based on type and provider.
metadata_url = https://example.com/auth/realms/<realm>
                            # URL to get OIDC metadata from. Can be obtained
                            # from the provider.
                            # It usually contains a realm or tenant id.
client_id = <client-id>
                            # OIDC client secret. Can be obtained from the
                            # provider. Some providers call this "app id".
client_secret = <client-secret->
                            # OIDC client secret. Can be obtained from the
                            # provider. Some providers call this "secret value".
hidden = false
                            # it is possible to hide an authentication provider
                            # on the SKOOR Auth start page. This can be useful
                            # if e.g. normal users authenticate against a public
                            # provider and support employees against an internal
                            # one.

Microsoft Azure AD OpenID Connect

SKOOR Auth Provider Entry

[provider.1]
type = oidc
name = Azure AD Example
issuer = microsoft
metadata_url = https://login.microsoftonline.com/<tenant-id>/v2.0
client_id = <app-id>
client_secret = <secret-value>

The icon is set automatically based on the issuer name.

Required Settings in Azure AD

Azure group ID to match SKOOR remote group:

In order to allow users to login and get the correct Role assigned these ID’s must be configured.
In the example below, all Users in the Azure AD Group with the ID c2b2***** will have the administrator role after login:

App registration

In your Azure Active Directory you register a new application, choose supported account types based on your AD Setup (Single- or Multi- tenant).
As Redirect URI configure the following, depending on which services your server has activated. This can also be edited later on.

Skoor Engine / Skoor Dashboard

https://<FQDN>/skoor-auth/oidc/code

Skoor Dashboard Viewer

https://FQDN/skoor-dashboard-viewer-auth/oidc/code

Tenant ID & Client ID

Once the application registration is saved, open the overview tab of the created application and take note of the two ID’s which will later be required for the configuration. These are called:

  • Application (client) ID

  • Directory (tenant) ID

Certificates & secrets

Next, go to Certificates & secrets and add a client secret. Set a name for this secret and pick an expiration date. Once saved you can see the secret id and the secret value. The secret value is later required to configure the Skoor Auth service.

Token

Go to the token configuration and select ‘add groups claim'. In the claim configuration select ‘Security groups’ and select the token property Type ‘ID’ to ‘sAMAccountName’.

API Permission

This step is optional. To enable more details on the user configuration in Skoor, for example the profile picture, the application needs permission to read the full user profile.
Therefor you can perform the following steps in the tab ‘API permissions’:

  • Add permission

  • Select Microsoft Graph

  • Delegated Permissions

  • Search for User.Read or scroll the section ‘user’ and select ‘User.Read’ then click ‘add permission’

  • Back in the overview confirm the permission by selecting ‘Grant admin consent’

Keycloak

SKOOR Auth Provider Entry

[provider.2]
type = oidc
name = SKOOR Keycloak
issuer = skoor
icon = url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+CjxzdmcKICAgeG1sbnM6ZGM9Imh0dHA6Ly9wdXJsLm9yZy9kYy9lbGVtZW50cy8xLjEvIgogICB4bWxuczpjYz0iaHR0cDovL2NyZWF0aXZlY29tbW9ucy5vcmcvbnMjIgogICB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiCiAgIHhtbG5zOnN2Zz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciCiAgIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIKICAgeG1sbnM6c29kaXBvZGk9Imh0dHA6Ly9zb2RpcG9kaS5zb3VyY2Vmb3JnZS5uZXQvRFREL3NvZGlwb2RpLTAuZHRkIgogICB4bWxuczppbmtzY2FwZT0iaHR0cDovL3d3dy5pbmtzY2FwZS5vcmcvbmFtZXNwYWNlcy9pbmtzY2FwZSIKICAgdmlld0JveD0iMCAwIDI1LjAwMDAwMSAyNSIKICAgaGVpZ2h0PSIyNSIKICAgd2lkdGg9IjI1IgogICB4bWw6c3BhY2U9InByZXNlcnZlIgogICBpZD0ic3ZnMiIKICAgdmVyc2lvbj0iMS4xIgogICBzb2RpcG9kaTpkb2NuYW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dXJ2YXR1cmU9IjAiIC8+PC9zdmc+')
metadata_url = https://<keycloak-server-address>/auth/realms/<realm>
client_id = <client-id>
client_secret = <client-secret>

Since we have a custom issuer, we have to provide an icon to display next to the name. We can provide the icon using a data URL.

Required Settings in Keycloak

The following is a minimum configuration to get a OIDC with Keycloak working. This can be used if you don’t already have an OIDC compatible authentication provider and want to authenticate your users against an internal active directory.

Realm Settings

If you don’t already have a realm configured, you have do add one. A good realm name might be your company name. This name is the value you need to insert as <realm> in your provider entry.

It might be a good idea to enable Remember Me option on the Login tab.


Clients

You have to add a client configuration for SKOOR.

Client ID has to be inserted as <client_id> in you provider config.

Client protocol has to be openid-connect.

Access Type has to be confidential

Standard flow has to be enabled.

Redirect URLs should be set to the following values:

Skoor Engine / Skoor Dashboards

https://<FQDN>/skoor-auth/oidc/code

Skoor Dashboard Viewer

https://FQDN/skoor-dashboard-viewer-auth/oidc/code

The client secret needed for the <client_secret> provider config you can get from the Credentials tab.

Client Scopes

In order to get group information for a user, an additional mapper called groups has to be added to the profile scope.

User Federation

In order to be able to authenticate against a active directory, a LDAP provider has to be added.

This settings heavily depends on your AD configuration

One very important step is to add a mapper of type group-ldap-mapper.

Kerberos

If Kerberos SSO is needed, this can be activated in the Authentication menu