[UWP] Login via OpenId Connect IdentityProvider - We can't connect to the service you need right now. Check your network connection or try this again later.
See original GitHub issueHello,
I have already implemented your sample into an external app, but i got errors while login with an openid identity provider.
To reproduce this problem I checked out your latest master, tried to reproduce this error within your solution and it also occurs there. I just changed the B2CConstants file values and everything is working for local accounts. In my Azure B2C I have created 2 identity providers for different AD’s in my signin/signup policy.
For Android and iOS everything works fine as expected, also the login with the identity provider. If I log in with the UWP App via the identity provider i get the following error:
In my external app, sometimes its possible to login via the identity provider if I first login with local account ⇒ logout and login again with identity provider credentials. But its not really a workaround because the error comes again on the next login.
I configured the identity provider with following documentation:
https://docs.microsoft.com/de-de/azure/active-directory-b2c/tutorial-add-identity-providers
I tried following things:
add Capabilities:
<Capabilities>
<Capability Name="internetClient" />
<uap:Capability Name="enterpriseAuthentication"/>
<Capability Name="privateNetworkClientServer"/>
<uap:Capability Name="sharedUserCertificates"/>
<uap:Capability Name="userAccountInformation"/>
<Capability Name="internetClientServer"/>
</Capabilities>
found it here: https://github.com/Azure-Samples/active-directory-b2c-xamarin-native/issues/137
And tried also setting the registry and redirect url which is created from the app during execution: https://github.com/AzureAD/microsoft-authentication-library-for-dotnet/wiki/UWP-specifics#properties-of-platformparameter-specific-to-winrt-and-uwp-corporate-network
Im not quite sure what im missing or doing wrong, hope you can help me.
Thank you!
/edit Maybe some additional information, I developed the identity provider login with a signIn/signUp (default) policy, that was working at the beginning, the error occurs only sometimes. After I changed to a only signin (default) policy, the error occurs nearly every time (only works with the workaround which i described already).
Issue Analytics
- State:
- Created 3 years ago
- Comments:20
thanks @MichaelWytek i’ve passed the information along to b2c team.
@jennyf19 Thanks for the input, I tried it now and its working again for me with the recommended policy type 😄.
But I was able to reproduce the “Cant connect to the service you need right now” again with following steps, also with the recommended policy type:
Then i tried to login/logout a few times:
Maybe it is possible to have “wrong” configuration within the identityprovider? Is there any setting which can have side effects to the B2C Login which is set directly in the IdentityProvider AD? I did not understand why I was able to Login to the “DF AD” at the beginning, and since I logged into the “Customer AD” I was not able to login to the “DF AD” again.
/e tried it also on the newest master of this Project (active-directory-b2c-xamarin-native) and the login didnt work for my "DF AD "IdentityProvider, for the “Customer AD” IdentityProvider it works as well.
The good thing is that the “DF AD” is only for the test/dev Stage 😄
Thank you,
BR.