mirror of
https://github.com/bitwarden/server
synced 2025-12-11 13:53:40 +00:00
Dont run custom token logic for org based client_ids explicitly (#992)
* Dont run custom token logic for org based client_ids explicitly * org to organization
This commit is contained in:
@@ -44,7 +44,8 @@ namespace Bit.Core.IdentityServer
|
|||||||
public async Task ValidateAsync(CustomTokenRequestValidationContext context)
|
public async Task ValidateAsync(CustomTokenRequestValidationContext context)
|
||||||
{
|
{
|
||||||
string[] allowedGrantTypes = { "authorization_code", "client_credentials" };
|
string[] allowedGrantTypes = { "authorization_code", "client_credentials" };
|
||||||
if (!allowedGrantTypes.Contains(context.Result.ValidatedRequest.GrantType))
|
if (!allowedGrantTypes.Contains(context.Result.ValidatedRequest.GrantType) ||
|
||||||
|
context.Result.ValidatedRequest.ClientId.StartsWith("organization"))
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user