Add support for calling WithClientClaims flow for token acquisition - #3623
Merged
Merged
Conversation
added 6 commits
December 7, 2025 19:26
Contributor
|
Travis Walker (@trwalke) I've opened a new pull request, #3703, to work on those changes. Once the pull request is ready, I'll request review from you. |
added 5 commits
February 3, 2026 22:17
Bogdan Gavril (bgavrilMS)
approved these changes
Feb 4, 2026
Bogdan Gavril (bgavrilMS)
left a comment
Member
There was a problem hiding this comment.
Approved with comments.,
Nilesh Choudhary (4gust)
approved these changes
Feb 4, 2026
Travis Walker (trwalke)
approved these changes
Feb 4, 2026
This was referenced Jul 13, 2026
Closed
Closed
This was referenced Jul 27, 2026
Closed
Closed
This was referenced Aug 3, 2026
Closed
This was referenced Aug 12, 2026
Merged
This was referenced Aug 19, 2026
This was referenced Sep 7, 2026
This was referenced Sep 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request updates the Microsoft Identity Web library to support passing custom client assertion claims during token acquisition, and upgrades the Microsoft Identity Client dependency version. The main changes involve adding logic to extract client claims from the provided options and pass them to the underlying authentication builder methods, as well as handling serialization. Several usages of obsolete APIs are now explicitly suppressed with pragma directives.
Dependency update:
MicrosoftIdentityClientVersionfrom4.77.1to4.82.0inDirectory.Build.props, ensuring the project uses the latest features and fixes from the Microsoft Authentication Library.Support for custom client assertion claims:
GetClientClaimsIfExistinTokenAcquisition.csto extract and serialize client claims fromTokenAcquisitionOptions, and integrated it into the main token acquisition flows (GetAuthenticationResultForUserAsync,GetAuthenticationResultForAppAsync,GetAuthenticationResultForWebAppWithAccountFromCacheAsync, andNotifyCertificateSelection). This enables passing custom client assertion claims to the authentication builder. [1] [2] [3] [4] [5]API usage and code quality:
WithExtraQueryParameters) by adding pragma directives around affected calls throughoutTokenAcquisition.cs. [1] [2] [3] [4] [5]Other improvements:
Serialization support:
using System.Text.Json;directive to enable JSON serialization of client claims.Add support for calling WithClientClaims flow for token acquisitionEnabling MSAL's WithClientClaims flavor of client assertions call and exposing it through IdWeb.