p2-inc / keycloak-orgs

Single realm, multi-tenancy for SaaS apps
Other
362 stars 65 forks source link

Logged inuser added to organization automatically with all default roles when creating new organization - v23.0.5 #189

Closed dileep-ehr closed 4 months ago

dileep-ehr commented 4 months ago

Docker version 23.0.5

Steps to reproduce

  1. Login to master domain as admin
  2. create a new realm and change to it
  3. create a user and give all realm admin roles including organization roles
  4. logout admin and login in to the new realm with the new user
  5. Create a new organization

Now the logged in user is mapped to the new organization automatically with all organization related default roles.

Is this the expected behavior? Since this may be an realmAdmin user who is not part of all the organizations, we have to manually delete this user from all new organizations.

xgp commented 4 months ago

This is expected. The creator of an organization automatically defaults to be the organization admin.