Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

The application requesting authentication tokens is either disabled or incorrectly configured

I was trying for microsoft login in my windows 10 UWP app.

var authenticator = new Windows.Security.Authentication.OnlineId.OnlineIdAuthenticator();
var serviceTicketRequest = new Windows.Security.Authentication.OnlineId.OnlineIdServiceTicketRequest("wl.basic", "DELEGATION");

System.Diagnostics.Debug.WriteLine("Signing in...");

var authResult = await authenticator.AuthenticateUserAsync(serviceTicketRequest);

this was the code I was trying. I got exception at authenticator.AuthenticateUserAsync The exception was

Exception thrown: 'System.Exception' in mscorlib.ni.dll

Additional information: The application requesting authentication tokens is either disabled or incorrectly configured. (Exception from HRESULT: 0x80860003) Anyone have Idea why this happening?

like image 449
Alias Varghese Avatar asked Feb 07 '23 05:02

Alias Varghese


1 Answers

The exception here is that your app didn't associate with the Windows Store.

To associate your app with the Windows Store, open your app's project file in Visual Studio:

  1. From the Store menu, select Associate App with the Store... enter image description here
  2. Click Sign in to sign into your Windows Store developer account using your Microsoft account credentials. If you don't have a Windows Store developer account, go to your Windows Store Dashboard to create one, and then restart this procedure.
  3. Select the app from the list with which you want to associate your app in Visual Studio. If the app is not listed, click Reserve name to add it to your Windows Store developer account.
  4. Click Next to review the info that the wizard will add to your app.
  5. If the info looks correct, click Associate and the wizard will update your app's package manifest.

After associating, you can avoid this exception and authenticate user with Microsoft Account.

like image 176
Jay Zuo Avatar answered Feb 16 '23 04:02

Jay Zuo