public static IActionResult InvalidAuthorization(this ControllerBase controller, AuthorizationRequestError error) { switch (error.ResponseMode) { case OpenIdConnectResponseMode.FormPost: return(controller.FormPost(error)); case OpenIdConnectResponseMode.Fragment: return(controller.Fragment(error)); case OpenIdConnectResponseMode.Query: return(controller.Query(error)); default: return(new BadRequestResult()); } }
public static IActionResult Query(this ControllerBase controller, AuthorizationRequestError error) { return(new QueryResult(error.RedirectUri, error.Message.Parameters)); }