sliceofbytes / Umbraco-OpenIdConnect-Example

An example to show how Umbraco and OpenIdConnect work together

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Umbraco OpenID Connect example package

This example shows how OpenID Connect can be used for members in Umbraco. It's a complete Umbraco solution with a SQLite database. Everything is already configured correct so you can just download the project and run it.

It's based on the external login providers documentation:
https://our.umbraco.com/documentation/reference/security/external-login-providers/

This example only works on Umbraco 10.2 or higher.

Backoffice credentials:

Username umbraco-openidconnect@mailinator.com
Password AKXT9fJGqBvKCVK5TqNZ

External member credentials:

Username openidconnect-example@mailinator.com
Password juSp#&uf4a+omLkigIto

Getting started

You can watch a getting started video here: https://youtu.be/cklH7DtRDIQ

Important files

All important files that are used for this setup are in the Umbraco-OpenIdConnect-Example.Core project.

  1. OpenIdConnectMemberExternalLoginProviderOptions.cs
    This file is used to setup the auto link options.
  2. UmbracoBuilderExtensions.cs
    Extensions used to setup OpenID Connect and the related events.
  3. ExternalLogoutController.cs
    A new controller used for logout on the external login provider.

Short demo

Umbraco OpenID Connect demo

Auth0

There is a free Auth0 account that this project connects with. The Client ID and Client Secret are already configured for that. Normally the Client Secret should not be in Github, but these settings are only used in this example so it's ok they are public. This is the project:

About

An example to show how Umbraco and OpenIdConnect work together

License:MIT License


Languages

Language:JavaScript 85.8%Language:CSS 8.1%Language:HTML 4.3%Language:C# 1.8%