Skip to content

Releases: AzureAD/microsoft-authentication-library-for-dotnet

MSAL.NET Version 3.0.0-preview

27 Feb 21:57
dce797c
Compare
Choose a tag to compare
Pre-release

Breaking changes in MSAL.NET 3:

  • UIBehavior was renamed to Prompt (breaking change)
  • TokenCacheNotificationArgs now surfaces an ITokenCache instead of a TokenCache. This will allow MSAL.NET to provide, in the future, various token cache implementations.
  • TokenCacheExtensions was removed and its methods moved to ITokenCache (this is a binary breaking change, but not a source level breaking change)
  • The Serialize and Deserialize methods on TokenCacheExtention (which were serializing/deserializing the cache to the MSAL v2 format) were moved to ITokenCache and renamed SerializeMsaV2 and `DeserializeV2

Changes related to improving app Creation and configuration MSAL issue

  • New class ApplicationOptions helps you build an application, for instance, from a configuration file
  • New interface IMsalHttpClientFactory to pass-in the HttpClient to use by MSAL.NET to communicate with the endpoints of Microsoft identity platform for developers.
  • New classes PublicClientApplicationBuilder and ConfidentialClientApplicationBuilder propose a fluent API to instantiate respectively classes implementing IPublicClientApplication and IConfidentialClientApplication including from configuration files, setting the targetted cloud and audience, but also setting per application logging and telemetry, and setting the HttpClient.
  • New delegates TelemetryCallback and TokenCacheCallback can be set at application construction
  • New enumerations AadAuthorityAudience and AzureCloudInstance help you writing applications for sovereign and national clouds, and help you choose the audience for your application.

Changes related to improving token acquisition, addressing issues 810, 635, 426, 799 :

  • ClientApplicationBase now implements IClientApplicationBase and has new members:
    • AppConfig of new type IAppConfig contains the configuration of the application
    • UserTokenCache of new type ITokenCache contains the user token cache (for both public and confidential client applications for all flows, but AcquireTokenForClient)
      • New fluent API AcquireTokenSilent
  • PublicClientApplication and IPublicClientApplication have four new fluent APIs: AcquireTokenByIntegratedWindowsAuth, AcquireTokenByUsernamePassword, AcquireTokenInteractive, AcquireTokenWithDeviceCode.
  • ConfidentialClientApplication has new members:
    • AppTokenCache used by AcquireTokenForClient
    • Five new fluent APIs: AcquireTokenByAuthorizationCode, AcquireTokenForClient, AcquireTokenOnBehalfOf, GetAuthorizationRequestUrl, IByRefreshToken.AcquireTokenByRefreshToken
  • New extensibility mechanism to enable public client applications to provide, in a secure way, their own browsing experience to let the user interact with the Microsoft identity platform endpoint (advanced). For this, applications need to implement the ICustomWebUi interface and throw MsalCustomWebUiFailedException exceptions in case of failure. This can be useful in the case of platforms which don't have yet a Web browser. For instance, the Visual Studio Feedback tool is an Electron application which uses this mechanism. MSAL issue
  • MsalServiceException now surfaces two new properties:
    • CorrelationId which can be useful when you interact with Microsoft support.
    • SubError which indicates more details about why the error happened, including hints on how to communicate with the end user. MSAL issue

Changes related to the token cache:

  • New interface ITokenCache contains primitives to serialize and deserialize the token cache and set the delegates to react to cache changes
  • New methods SerializeMsalV3 and DeserializeMsalV3 on ITokenCache serialize/deserialize the token cache to a new layout format compatible with other MSAL libraries on Windows/Linux/MacOS.

A few bug fixes:

MSAL.NET Version 2.7.1

21 Feb 18:22
b53d446
Compare
Choose a tag to compare

2.7.1

  • MSAL now handles B2C domains from sovereign clouds, including US Government, Blackforest, and Mooncake. B2C domains with *.b2clogin.us, *.b2clogin.cn, and *.b2clogin.de are now included in the MSAL allowed domain list for B2C authorities. MSAL issue
  • Improved error message handling to detect issues faster and not hit null reference exceptions. Sometimes, for example, when the instance discovery endpoint is not found, the Oauth2Client in MSAL would hit a null reference exception. MSAL now detects such issues faster and returns a more meaningful error message (e.g. the http response code).

MSAL.NET Version 2.7.0

16 Jan 17:13
4262e8c
Compare
Choose a tag to compare

2.7.0

  • MSAL integrates SourceLink https://github.com/dotnet/sourcelink. This allows MSAL to embed pdb files and source code in the NuGet package, allowing users to debug into MSAL without replacing their package reference with a project reference. MSAL PR
  • MSAL.NET now supports Xamarin.Mac. We now ship another MSAL assembly, that can be used when building apps using Xamarin.Mac. MSAL.NET for Xamarin.Mac supports interactive authentication via an embedded browser, as well as silent authentication. It does not serialize its token cache to the keychain, instead users are asked to provide their own serialization mechanism as they see fit. A keychain based implementation will likely be implemented in a future release. MSAL PR
  • Easier migration from ADALv2 to MSALv2 due to a new AcquireTokenFromRefreshToken API. ADAL.NET v2.x exposes the refresh token in the AuthenticationResult, as well as methods to acquire a token from a refresh token in the AuthenticationContext. Through the ConfidentialClientApplication, MSAL now implements an explicit interface to help customers migrate from ADAL v2 to MSAL v2. With this method, developers can provide the previously used refresh token along with any scopes. The refresh token will be exchanged for a new one and cached. Please see https://aka.ms/msal-net-migration-adal2-msal2 for more details. MSAL issue
  • Token cache account was not being deleted on Android platform. MSAL PR
  • When using ADAL v4.4.2 and MSAL v2.6 in the same Xamarin project, an error would result of Cannot register two managed types due to the iOS view controllers being registered under the same name. Now the MSAL iOS view controllers are prefixed with MSAL so they are distinct from the ones in ADAL. MSAL issue
  • When using the KeychainSecurityGroup property to enable application sharing of the token cache, developers were required to include the TeamId. Now, MSAL resolves the TeamId at runtime. A new property iOSKeychainSecurityGroup should be used instead. See https://aka.ms/msal-net-ios-keychain-security-group for details. MSAL issue

MSAL.NET Version 2.6.2

20 Dec 00:23
3cfd9a1
Compare
Choose a tag to compare

2.6.2

  • Move AuthenticationContinuationHelper class back to the Microsoft.Identity.Client namespace to avoid breaking changes to existing Android and iOS apps.
  • Fix issue in 2.6.1 where strongnamer package was marked as a nuget package dependency.

MSAL.NET Version 2.6.1

18 Dec 20:58
4e06932
Compare
Choose a tag to compare

2.6.1

  • Setting ForceRefresh = true in AcquireTokenSilent used to skip access token cache lookup MSAL now handles ForceRefresh=true correctly and circumvents looking up an access token in the cache, instead using the refresh token to acquire a new access token. MSAL issue #695
  • Ensured cache lookup filters on the specified tenantId, otherwise the cache lookup would always find the token for the home tenant This enables MSAL to acquire tokens for resources outside the home tenant. MSAL issues #694

MSAL.NET Version 2.6.0-preview

14 Dec 19:33
a2c5491
Compare
Choose a tag to compare
Pre-release

2.6.0-preview

  • For more info on the release, see https://aka.ms/msal-net-2-6 for details
  • Improved error messages for Integrated Windows Auth: MSAL now returns better error messages for managed users using Integrated Windows Auth. ADAL issue #1398
  • New parameter for UIBehavior: B2C developers can now use NoPrompt as a UIBehavior. For example, when envoking the edit profile policy to avoid the account selection UI and move directly to the edit profile UI. MSAL issue #588
  • UIParent is available on all platforms: The UIParent constructor now takes in (object parent, bool useEmbeddedWebview) and is available on all platforms. MSAL issue #676
  • Remove dependency on Newtonsoft.Json: MSAL now uses Microsoft.Identity.Json MSAL PR
  • Deprecate HasStateChanged: MSAL was not using this flag, so it has been deprecated ADAL issue #1186
  • Obsolete public WebUI net45 types from Internal.UI namespace: MSAL
  • NetStandard Unification: MSAL.NET helps you build multi-platform applications more easily by rationalizing the .NET Standard 1.3 platform. For details see blog post about this release available from: https://aka.ms/msal-net-2-6
  • Public namespace change: If you implement dual serialization (AdalV3/Unified cache), and therefore are using Microsoft.Identity.Core.Cache to access some of the public cache classes, please note the namespace has changed to Microsoft.Identity.Client.Cache. You will get this error when updating packages: The type or namespace name 'Core' does not exist in the namespace 'Microsoft.Identity' (are you missing an assembly reference?). Just replace Core with Client in the using statement.
  • Move MSAL code to the MSAL repo

1.1.4-preview

01 Jun 03:06
ff5b29d
Compare
Choose a tag to compare
1.1.4-preview Pre-release
Pre-release

1.1.4-preview

Hot fix of null pointer in iOS TokenCacheAccessor(#570)

Version 1.1.3-preview

25 May 19:27
Compare
Choose a tag to compare
Version 1.1.3-preview Pre-release
Pre-release

1.1.3-preview

This release contains updates to Xamarin.Android.Support v27.0.2 and MonoAndroid8.1 (#553 #520).

1.1.2-preview

02 Feb 18:45
Compare
Choose a tag to compare
1.1.2-preview Pre-release
Pre-release

1.1.2-preview

This releases fixes references issues for Xamarin Android (for instance #520 & #524).
When you create a new Xamarin Forms project and reference MSAL this now works out of the box.
If you want to migrate an existing project to MSAL 1.1.2, please read the wiki page.
(https://github.com/AzureAD/microsoft-authentication-library-for-dotnet/wiki/Troubleshooting-Xamarin.Android-issues-with-MSAL)

1.1.1-preview

06 Jan 02:17
Compare
Choose a tag to compare
1.1.1-preview Pre-release
Pre-release

1.1.1-preview

This release contains -

  • Added support to use RSACng in .net 4.7 (#448)
  • Expose claims as an attribute for MSALUiRequiredException (#459)
  • Updated Xamarin Forms Android support libraries to 25.3.1 (#450)
  • Added Arlington URL to list of trusted authorities (#495)
  • Changes for GDPR complicance with PiiLogs (#492)
  • Several bug fixes