Error and error_description parameters lost in redirect to login-failed in Blazor

I’m using Auth0 to authenticate in my Blazor WASM app on .NET 8. I followed this tutorial and it all works great! How to Secure Blazor WASM Applications with Auth0

Except for one thing. I’m using a custom Action that checks if the user’s email is confirmed and if it is not, it denies access. This is returned to the login-callback endpoint in the “error” and “error_description” parameters of the URL.

However, it seems that as soon as the RemoteAuthenticatorView component determines that the login failed, it redirects the user to login-failed. It also seems like if there is a “message” parameter this will get passed along. But the “error” and “error_description” parameters do not get passed along, so I have no way to tell the user what the problem was, ie their email is not confirmed.

Can anyone help? The only two things I’ve found for the same problem online are two Reddit threads that never got any replies.

Thanks!

Any chance of getting some help on this?

@andrea.chiarelli I know you are kind of the Blazor guru, do you have any suggestions for me?

Hey @ms4sman,
Sorry for being late to the party :slight_smile:
Thanks for your trust, but I’m not a Blazor guru :slight_smile: I still have a lot to learn…

Regarding your issue, maybe the section of this article can give you some inspiration.
I haven’t tried this approach with Blazor, but I think it should work.

Let me know.