Skip to content

Blazor - Shared login page with multi-tenant users #854

Open
@Conway6288

Description

Looking to create an application which has a single login page for all users. Each user will be assigned to at least one tenant but they can be assigned to multiple and would need to switch between them after logging in. Each tenant needs to be isolated so FinBuckle seems like the perfect solution.

Currently exploring the use of the Claims Strategy, with a user's available tenants being listed in a claim. This works out of the box with the claims strategy assuming there is only one tenant. I have also looked at using the base path strategy, but would still need to do an initial redirect after login to whatever the default tenant is deemed to be. If they change their active tenant, we would then need to redirect them to the current base path or somehow toggle that from the claim.

This has raised several questions:

  • Once logged in, how do you determine and select a default tenant if they have access to multiple?
  • What is the best practice for switching between the available tenants after logging in based on user interaction?
  • Is one strategy recommended over another with this scenario?

I had a look through previous discussions and found several old threads related to this:

That also led me to find the SharedLoginSample here.

Is there an updated example for the SharedLogin anywhere (Ideally for Blazor) or "hot swapping" between tenants after login?

Many thanks in advance, any help or advice appreciated.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions