ClientApplicationBase.UserTokenCache Property

Definition

User token cache. It holds access tokens, id tokens and refresh tokens for accounts. It's used and updated silently if needed when calling AcquireTokenSilent(IEnumerable<String>, IAccount) or one of the overrides of AcquireTokenSilent(IEnumerable<String>, IAccount). It is updated by each AcquireTokenXXX method, with the exception of AcquireTokenForClient which only uses the application cache (see IConfidentialClientApplication).

C#
public Microsoft.Identity.Client.ITokenCache UserTokenCache { get; }

Property Value

Implements

Remarks

On .NET Framework and .NET Core you can also customize the token cache serialization. See https://aka.ms/msal-net-token-cache-serialization. This is taken care of by MSAL.NET on mobile platforms and on UWP. It is recommended to use token cache serialization for web site and web api scenarios.

Applies to

Product Versions
Microsoft Authentication Library for .NET (MSAL.NET) latest