Open KristofferBerge opened 4 years ago
Our use case is to find a value in the scope claim. The scope claim contains a list of scopes. If there was a claim contains rule, we would not have to implement this ourselves.
➤ Einar Ingebrigtsen commented:
Are you looking for a value within the claim value, or is it the whole value. If it's the latter, you could use the method called HasClaimTypeWithValue(). (https://github.com/dolittle-fundamentals/DotNET.Fundamentals/blob/master/Source/Security/IUserSecurityActor.cs)
The scope claim contains a list of values. I would like to check if a given value is in that list
It's not easy to extend the UserSecurityActor to check more than Roles and Claims because it does not expose the ClaimsPrincipal.
If it exposes that we can extend it to check for whatever we need.
┆Issue is synchronized with this Asana task