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.

Sorry it took me a bit to get back here.

I’ll take a look into that article when I get a chance, it seems like it might work!

In the meantime, I ended up moving on to another Identity solution for my current project, but I do still have Auth0 on some other projects and have the same issue there, so when I have a chance, I’ll try it on those before moving them to another Identity platform as well.

Thanks for responding!