-
Notifications
You must be signed in to change notification settings - Fork 880
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
## Description This PR adds generic OIDC as an authentication provider. This allows personal users and companies potentially to define whatever IdP they want as long as it supports the OIDC well known format. (Azure, Zitadel, Authentik, KeyCloak, Google, etc. all support it) ## Related Issue Fixes #1090 ## Changes Made - Adds OIDC buttons to the signin and registration pages - Adds appropriate environment variables - Adds migration to add OIDC to the `IdentityProvider` Enum ## Testing Performed #### Zitadel - Created application in Zitadel as an web app, with Client auth - Enabled `User Info inside ID Token` in Token settings - Copied client id and client secret to the new .ENV variables - Copied the well-known URL from the URLs section to .ENV - Created new account with OIDC provider button - Verified email manually - Signed into account with OIDC provider - Logged out - Signed into accounting again with OIDC provider #### Authentik - Created application in Authentik - Copied client id and client secret to the new .ENV variables - Copied the well-known URL from the URLs section to .ENV - Created new account with OIDC provider button - Verified email manually - Signed into account with OIDC provider - Logged out - Signed into accounting again with OIDC provider #### Azure AD - Created application in Azure AD using OAuth2 - Copied client id and client secret to the new .ENV variables - Copied the well-known URL from the URLs section to .ENV - Created new account with OIDC provider button - Verified email manually - Signed into account with OIDC provider - Logged out - Signed into accounting again with OIDC provider
- Loading branch information
Showing
14 changed files
with
179 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
packages/prisma/migrations/20240413202001_add_oidc_auth/migration.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TYPE "IdentityProvider" ADD VALUE IF NOT EXISTS 'OIDC'; |
3 changes: 3 additions & 0 deletions
3
...isma/migrations/20240530120101_add_missing_fields_to_account_model_for_oidc/migration.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
-- AlterTable | ||
ALTER TABLE "Account" ADD COLUMN "created_at" INTEGER, | ||
ADD COLUMN "ext_expires_in" INTEGER; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters