boundless-artist-2317
10/07/2024, 11:27 AMbland-eye-99092
10/07/2024, 11:33 AMboundless-artist-2317
10/07/2024, 11:38 AMbland-eye-99092
10/07/2024, 11:39 AMboundless-artist-2317
10/07/2024, 11:46 AM<http://example.com|example.com>
here instead of actual domain for privacy/security):
• @mail.example.com
Let's call the problem account <mailto:mark@example.com|mark@example.com>
. As part of some testing, I registered this account using the B2B SSO config. I did this by typing <mailto:mark@mail.example.com|mark@mail.example.com>
into the sign-up form but then when signing in with my 3rd party IdP, I used <mailto:mark@example.com|mark@example.com>
.
I saw the screenshotted error above when trying to access the settings page. So then I removed the OIDC authentication methods for this account using the /admin/identities
API:
curl -X DELETE ${ORY_SDK_URL}/admin/identities/{identity-id}/credentials/oidc?identifier={oidc-credential-id}
However, when I try to access the settings page, I still see the error above.
The strange thing is that when I try to log in with a different account that has never used the B2B SSO login flow (e.g. <mailto:mark+temp@example.com|mark+temp@example.com>
), I am able to login and access the settings page successfully.
So it looks like there is some stale data introducing corruption and preventing login.boundless-artist-2317
10/07/2024, 12:40 PMorganization_id
field in the identity object is still non-null. Identity retrieved using:
curl -X GET ${ORY_SDK_URL}/admin/identities/{id} \
-H "Authorization: bearer ${ORY_API_KEY}" | jq -r
Replacing the organization ID with null solves the problem.
This looks like a bug to me. If an Enterprise SSO OIDC connection is disconnected from an identity, the organization ID should also be deleted from the identity metadata, correct?boundless-artist-2317
10/07/2024, 12:43 PMbland-eye-99092
10/07/2024, 1:49 PMrefined-kangaroo-48640
10/07/2024, 4:02 PMmagnificent-energy-493
boundless-artist-2317
10/08/2024, 2:49 PMIf you delete the OIDC connection, do you expect the users who have signed up with B2B SSO to simply be released into the "normal"/"public" user pool? That seems to me would have a bunch of weird implications.Yes, we would not want such users to be released into the public pool in our use case. The situation above was encountered because I was trying to test out the Enterprise SSO registration flow for only 1 of N users in the organisation, before releasing it to all users. So I had to use the hack of a "mis-styped" email domain -
<http://mail.example.com|mail.example.com>
instead of <http://example.com|example.com>
.
A better solution could come through the ability to enable Enterprise SSO for individual email addresses within a given domain. This would simplify testing before full roll-out.