I'm working with an IdP that does not support CORS and trying to do a redirect binding. Their solution was to catch the response from the server and open the redirect in a new window. The browser keeps redirecting it for me. Is there a way to apply a custom response code in this sample:
Login method in the Auth Controller:
[Route("Login")]
public IActionResult Login(string returnUrl = null)
{
var binding = new Saml2RedirectBinding();
binding.SetRelayStateQuery(new Dictionary<string, string>
{ { relayStateReturnUrl, returnUrl ?? Url.Content("~/") } });
return binding.Bind(new Saml2AuthnRequest(config)).ToActionResult();
}