From 33a1d8ed8ce98cc85b8166dfbb0ee8d8e00f7e30 Mon Sep 17 00:00:00 2001 From: Millicent Achieng Date: Fri, 1 Mar 2024 17:27:50 +0300 Subject: [PATCH] Perform case insenstive match for paths when fetch permissions (#1976) --- PermissionsService/Services/PermissionsStore.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PermissionsService/Services/PermissionsStore.cs b/PermissionsService/Services/PermissionsStore.cs index b9809a678..d9f19e7bc 100644 --- a/PermissionsService/Services/PermissionsStore.cs +++ b/PermissionsService/Services/PermissionsStore.cs @@ -358,7 +358,7 @@ public async Task GetScopesAsync(List requests = } else { - var authZChecker = new AuthZChecker(); + var authZChecker = new AuthZChecker() { LenientMatch = true }; authZChecker.Load(permissionsDocument); var scopesByRequestUrl = new ConcurrentDictionary>(); @@ -478,7 +478,7 @@ private static IEnumerable GetAllScopesFromDocument(Permission else { return allPermissions - .Where(x => x.Value.Schemes.Keys.Any(k => k.Equals(scopeType.ToString(),StringComparison.OrdinalIgnoreCase))) + .Where(x => x.Value.Schemes.Keys.Any(k => k.Equals(scopeType.ToString(), StringComparison.OrdinalIgnoreCase))) .Select(grant => new ScopeInformation { ScopeName = grant.Key,