zeroframework/Services/Identity/ZeroFramework.IdentityServer.API/Extensions/CustomOAuthAuthenticationEvents.cs
2023-12-05 17:22:48 +08:00

25 lines
761 B
C#

using Microsoft.AspNetCore.Authentication;
using Microsoft.AspNetCore.Authentication.OAuth;
namespace ZeroFramework.IdentityServer.API.Extensions
{
public class CustomOAuthAuthenticationEvents : OAuthEvents
{
public override async Task RemoteFailure(RemoteFailureContext context)
{
//.Net Core Identity 2 Provider login Cancel leads to unhandled exception
await base.RemoteFailure(context);
}
public override Task TicketReceived(TicketReceivedContext context)
{
return base.TicketReceived(context);
}
public override async Task CreatingTicket(OAuthCreatingTicketContext context)
{
await base.CreatingTicket(context);
}
}
}