Authentication across multiple Blazor Server hosted and Blazor WASM applications

Hi,

I have one landing page SPA, which is a Blazor Server hosted application, hosted under https://myapp.com and I want to have multiple apps (Blazor WASM, Blazor Server hosted) und sub-paths like:

What I want to achieve is, to have only a single login under my landing page and when I navigate to app-one or app-two, then the same authenticated user shall be able to use that app.

What I did so far, is:

But it behaves not exactly as I expect. When I login on the landing page, then I can also access app-one. But when I’m in app-one and do the logout there, then I’m still logged-in in the landingpage. Also when logging-out from the landing page, then this has no effect on the app-one.

Is this conceptually correct how I want to share authentication across different applications, hosted under the same domain?

Regards

Hi @pascal1

Thanks for getting in touch with us here at Auth0 Community :slight_smile:

I think what’s happening here is when you log out of the landing page for example you clear the server session and application session for the landing page but the application session for app one is still valid. you will meed a mechanism on app one to clear the application session when the server session does not exist. Please review this document for some ideas https://auth0.com/docs/authenticate/login/logout/log-users-out-of-applications

Best regards.

1 Like