Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade MSAL dependencies to 4.59.1 #374

Merged
merged 3 commits into from
Apr 25, 2024
Merged

Conversation

Haard30
Copy link
Contributor

@Haard30 Haard30 commented Apr 24, 2024

Upgrading MSAL version to 4.59.1

Why not the latest 4.60.3?

There are few unresolved issues in 4.60.x version of MSAL for example:
[Bug] Broker-based flows fail for MSA accounts with latest MSAL.

Also, looking at the changelog, there does not seem to be an immediate need to move to 4.60.x, hence updating to a more stable version for now.

Selected improvements and bug fixes which can be helpful:

4.59.0 -
• Fixed a scenario when the same tokens are cached under different cache keys when an identity provider sends scopes in a different order.
• Fixed SemaphoreFullException happening in managed identity flows.

4.58.1 -
• Fixed an issue with sending an incorrect operating system descriptor in silent flows on Mac.
• Added WithForceRefresh support for silent flows using the Windows broker.

4.57 -
• Included missing Windows broker-related exception data when serializing MSAL exceptions.
• Added additional logging in the cache.

4.56 -
• Added AuthenticationResult.AuthenticationResultMetadata.Telemetry that currently contains telemetry from the Windows broker (WAM).
• Added clarity to the Windows broker logs.

Upgrading microsoft-authentication-extensions-for-dotnet

  • The MSAL Extensions repository has been archived and is maintained alongside MSAL.
  • Microsoft.Identity.Client.Extensions.Msal is now in sync with MSAL version. Note that repository mentions there are no breaking changes between 2.x and 4.x pic below)

image

Testing

Benchmark test

4.59.1

BenchmarkDotNet=v0.13.2, OS=Windows 11 (10.0.22631.3447)
Intel Core i7-10700 CPU 2.90GHz, 1 CPU, 16 logical and 8 physical cores
.NET SDK=8.0.204
  [Host]     : .NET 6.0.29 (6.0.2924.17105), X64 RyuJIT AVX2
  DefaultJob : .NET 6.0.29 (6.0.2924.17105), X64 RyuJIT AVX2
Method Mean Error StdDev
NativeBrokerBenchmark 56.71 ms 0.307 ms 0.272 ms
ManagedBrokerBenchmark 56.89 ms 1.070 ms 0.948 ms

4.55.0

BenchmarkDotNet=v0.13.2, OS=Windows 11 (10.0.22631.3447)
Intel Core i7-10700 CPU 2.90GHz, 1 CPU, 16 logical and 8 physical cores
.NET SDK=8.0.204
  [Host]     : .NET 6.0.29 (6.0.2924.17105), X64 RyuJIT AVX2
  DefaultJob : .NET 6.0.29 (6.0.2924.17105), X64 RyuJIT AVX2
Method Mean Error StdDev
NativeBrokerBenchmark 55.98 ms 0.265 ms 0.247 ms
ManagedBrokerBenchmark 55.50 ms 0.512 ms 0.453 ms

Other

Tested following commands on both mac and windows:

azureauth --help
azureauth aad --help
azureauth ado pat --help
azureauth ado token --help
azureauth ado pat scopes --help
azureauth info --help
azureauth ado token
azureauth ado pat
azureauth aad (with different output and auth modes)

@Haard30 Haard30 added the dependencies Pull requests that update a dependency file label Apr 25, 2024
@Haard30 Haard30 marked this pull request as ready for review April 25, 2024 18:21
@Haard30 Haard30 requested a review from a team as a code owner April 25, 2024 18:21
mijpeterson
mijpeterson previously approved these changes Apr 25, 2024
Copy link
Contributor

@mijpeterson mijpeterson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's nice to see many of our dependency versions converging.

evandigby
evandigby previously approved these changes Apr 25, 2024
Copy link

@evandigby evandigby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving as my question is non-blocking--just something to keep in mind as we merge.

src/AdoPat/AdoPat.csproj Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
@Haard30 Haard30 dismissed stale reviews from evandigby and mijpeterson via f8ed563 April 25, 2024 20:24
@mvanchaa
Copy link
Contributor

Thanks for adding a detailed description, @Haard30! Super helpful!

@Haard30 Haard30 merged commit 2a9839d into main Apr 25, 2024
11 checks passed
@Haard30 Haard30 deleted the user/haashah/upgrade-msal branch April 25, 2024 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants