🐛 Fix compile failed
This commit is contained in:
@@ -157,14 +157,14 @@ public class DysonTokenAuthHandler(
|
|||||||
{
|
{
|
||||||
// Handle JWT tokens (3 parts)
|
// Handle JWT tokens (3 parts)
|
||||||
case 3:
|
case 3:
|
||||||
{
|
{
|
||||||
var (isValid, jwtResult) = oidc.ValidateToken(token);
|
var (isValid, jwtResult) = oidc.ValidateToken(token);
|
||||||
if (!isValid) return false;
|
if (!isValid) return false;
|
||||||
var jti = jwtResult?.Claims.FirstOrDefault(c => c.Type == "jti")?.Value;
|
var jti = jwtResult?.Claims.FirstOrDefault(c => c.Type == "jti")?.Value;
|
||||||
if (jti is null) return false;
|
if (jti is null) return false;
|
||||||
|
|
||||||
return Guid.TryParse(jti, out sessionId);
|
return Guid.TryParse(jti, out sessionId);
|
||||||
}
|
}
|
||||||
// Handle compact tokens (2 parts)
|
// Handle compact tokens (2 parts)
|
||||||
case 2:
|
case 2:
|
||||||
// Original compact token validation logic
|
// Original compact token validation logic
|
||||||
@@ -190,8 +190,6 @@ public class DysonTokenAuthHandler(
|
|||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@@ -19,7 +19,7 @@ public class OidcProviderController(
|
|||||||
AppDatabase db,
|
AppDatabase db,
|
||||||
OidcProviderService oidcService,
|
OidcProviderService oidcService,
|
||||||
IConfiguration configuration,
|
IConfiguration configuration,
|
||||||
IOptions<OidcProviderOptions> options,
|
IOptions<OidcProviderOptions> options
|
||||||
)
|
)
|
||||||
: ControllerBase
|
: ControllerBase
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user