From d784fda8475f699bb5fff678f27b5d3767179405 Mon Sep 17 00:00:00 2001 From: Colin Beeby Date: Tue, 25 Feb 2025 15:21:38 +0000 Subject: [PATCH 1/2] Added moodle client configuration to appsettings.json --- Auth/LearningHub.Nhs.Auth/appsettings.json | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/Auth/LearningHub.Nhs.Auth/appsettings.json b/Auth/LearningHub.Nhs.Auth/appsettings.json index 1565fa4..c1aa5d7 100644 --- a/Auth/LearningHub.Nhs.Auth/appsettings.json +++ b/Auth/LearningHub.Nhs.Auth/appsettings.json @@ -181,6 +181,23 @@ "RequireConsent": false, "RequirePkce": true, "AllowOfflineAccess": true + }, + "moodle": { + "BaseUrl": "", + "ClientName": "", + "ClientSecret": "", + "AllowedGrantTypes": [ "authorization_code" ], + "RedirectUris": [ "/login/oidc/" ], + "PostLogoutUris": [ "/login/logout.php" ], + "AllowedScopes": [ "openid", "profile", "learninghubapi", "userapi", "roles", "learningcredentialsapi" ], + "BackChannelLogoutSessionRequired": true, + "BackChannelLogoutUri": "/login/logout.php", + "FrontChannelLogoutSessionRequired": true, + "FrontChannelLogoutUri": "/login/logout.php", + "UpdateAccessTokenClaimsOnRefresh": true, + "RequireConsent": false, + "RequirePkce": false, + "AllowOfflineAccess": true } }, "IdsClients": { From f8b8d3d61dbaeae6be751dfc45dce8dc27e08d9f Mon Sep 17 00:00:00 2001 From: Colin Beeby Date: Thu, 27 Feb 2025 10:05:49 +0000 Subject: [PATCH 2/2] Corrected RedirectUris for moodle client --- Auth/LearningHub.Nhs.Auth/appsettings.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Auth/LearningHub.Nhs.Auth/appsettings.json b/Auth/LearningHub.Nhs.Auth/appsettings.json index c1aa5d7..f746802 100644 --- a/Auth/LearningHub.Nhs.Auth/appsettings.json +++ b/Auth/LearningHub.Nhs.Auth/appsettings.json @@ -187,7 +187,7 @@ "ClientName": "", "ClientSecret": "", "AllowedGrantTypes": [ "authorization_code" ], - "RedirectUris": [ "/login/oidc/" ], + "RedirectUris": [ "/auth/oidc/" ], "PostLogoutUris": [ "/login/logout.php" ], "AllowedScopes": [ "openid", "profile", "learninghubapi", "userapi", "roles", "learningcredentialsapi" ], "BackChannelLogoutSessionRequired": true,