I am exploring the Active Directory Authentication Library (ADAL) using a Console application. And it is said that once a token is retrieved using oauth, the token retrieved is cached for the same resourcename, clientid and user logged in previously. While this works fine in a Win8.1 Native app, I can't manage to make it work with a console application.
Below is the code I am using to acquire the token:
AuthenticationContext authContext = new AuthenticationContext("https://login.microsoftonline.com/{tenantGUID}/", false);
var result = authContext.AcquireToken(APPResourceName, clientGUID, redirectUri, PromptBehavior.Auto);
Supposedly the PromptBehavior.Auto is supposed to only prompt the user when no such token is cached on Azure, and as I said this works perfectly in a Win8.1 Native App. Also I noticed that the prompt interface (the login UI) is a bit different when prompted from Native Win8.1 (desktop UI version) and the Console App (mobile UI version), is this normal?
Can please anyone point out why it does not work in a normal Console Application?