ASP.NET Core Authorize Redirection to wrong URL
<p>I am trying to run a web application with the following route mapped:</p>

<pre><code>        app.UseMvc(routes =&gt;
        {
            routes.MapRoute(
                "default",
                "WoL/{controller=Account}/{action=Login}/{id?}");
        });
</code></pre>

<p>If the user is not authenticated and tries to access a action having the AuthorizeAttribute, the user should be redirected to the default login URL (as seen above). But the user gets redirected to "/Account/Login" instead of "/WoL/Account/Login". How can I redirect the user to "/WoL/Account/Login", if the user is not authenticated? I have configured the following Cookie Authentication:</p>

<pre><code>        app.UseCookieAuthentication(new CookieAuthenticationOptions
        {
            LoginPath = new PathString("/WoL/Account/Login"),
            AutomaticChallenge = true
        });
</code></pre>