6.0 | APIScan | MSAL WithClientName#3360
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR backports the MSAL application building code to utilize CreateWithApplicationOptions, replacing undocumented APIs and streamlining builder configuration.
- Use of PublicClientApplicationBuilder.CreateWithApplicationOptions for a more robust application instance creation
- Conditional inclusion of ParentActivityOrWindow for NETFRAMEWORK builds
- Removal of redundant duplicated builder calls
Comments suppressed due to low confidence (1)
src/Microsoft.Data.SqlClient/src/Microsoft/Data/SqlClient/ActiveDirectoryAuthenticationProvider.cs:547
- Ensure that all necessary options required by the MSAL framework and your application context are configured in PublicClientApplicationOptions to fully replicate the previous behavior.
.CreateWithApplicationOptions(new PublicClientApplicationOptions {
...crosoft.Data.SqlClient/src/Microsoft/Data/SqlClient/ActiveDirectoryAuthenticationProvider.cs
Show resolved
Hide resolved
| .WithClientVersion(Common.ADP.GetAssemblyVersion().ToString()) | ||
| .WithRedirectUri(publicClientAppKey._redirectUri) | ||
| .Build(); | ||
| builder.WithParentActivityOrWindow(_iWin32WindowFunc); |
There was a problem hiding this comment.
This needs the reassignment fix too.
There was a problem hiding this comment.
I don't think there's anything to fix. Chaining returns the same object, not a new instance.
There was a problem hiding this comment.
Yep, after chat with @paulmedynski we are in agreement that there's nothing required here
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## release/6.0 #3360 +/- ##
===============================================
- Coverage 72.74% 72.70% -0.05%
===============================================
Files 285 285
Lines 59165 59162 -3
===============================================
- Hits 43042 43014 -28
- Misses 16123 16148 +25
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Description: Backporting rewriting MSAL application building code to use CreateWithApplicationOptions and avoid (formerly) undocumented APIs. See #3354 for full details of change.