Conversation
️✔️AzureCLI-FullTest
|
|
Hi @jiasli, |
️✔️AzureCLI-BreakingChangeTest
|
Collaborator
|
Enable PII log for troubleshooting purpose |
evelyn-ys
reviewed
Apr 7, 2025
| return {**self._msal_app_kwargs, "enable_broker_on_windows": self._enable_broker_on_windows} | ||
| return {**self._msal_app_kwargs, | ||
| "enable_broker_on_windows": self._enable_broker_on_windows, | ||
| "enable_pii_log": True} |
Member
There was a problem hiding this comment.
May I know why not adding this to _msal_app_kwargs?
Member
Author
There was a problem hiding this comment.
enable_pii_log only affects the WAM flow from PublicClientApplication:
If adding enable_pii_log to _msal_app_kwargs, it will be passed to ConfidentialClientApplication which doesn't support WAM at all.
self._decide_broker(allow_broker, enable_pii_log) def _decide_broker(self, allow_broker, enable_pii_log):
is_confidential_app = self.client_credential or isinstance(
self, ConfidentialClientApplication)
if is_confidential_app and allow_broker:
raise ValueError("allow_broker=True is only supported in PublicClientApplication")
evelyn-ys
approved these changes
Apr 7, 2025
bebound
approved these changes
Apr 8, 2025
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.
Related command
az loginDescription
MSAL hides the original
AADSTSerror when WAM is used (AzureAD/microsoft-authentication-library-for-python#698).This PR uses
enable_pii_logfrom AzureAD/microsoft-authentication-library-for-python#590 to print the originalAADSTSerror.We should carefully inspect that no PII is sent to the telemetry before merging this PR.As confirmed by MSAL (AzureAD/microsoft-authentication-library-for-python#590 (comment)),
enable_pii_logonly affects logs, not telemetry. In other words, the telemetry will not contain PII even whenenable_pii_logis set toTrue.Testing Guide
Before:
After: