Skip to content

Commit a3ebd7a

Browse files
committed
additional changes made in response to feedback
1 parent d9e2de8 commit a3ebd7a

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

lib/msal-core/src/UserAgentApplication.ts

+7-5
Original file line numberDiff line numberDiff line change
@@ -631,7 +631,7 @@ export class UserAgentApplication {
631631
*/
632632
acquireTokenSilent(userRequest: AuthenticationParameters): Promise<AuthResponse> {
633633
this.logger.verbose("AcquireTokenSilent has been called");
634-
this.logger.verbose(`AcquireTokenSilent params:\n${JSON.stringify(userRequest)}`);
634+
635635
// validate the request
636636
const request = RequestUtils.validateRequest(userRequest, false, this.clientId, Constants.interactionTypeSilent);
637637
const apiEvent: ApiEvent = this.telemetryManager.createAndStartApiEvent(request.correlationId, API_EVENT_IDENTIFIER.AcquireTokenSilent);
@@ -685,16 +685,18 @@ export class UserAgentApplication {
685685
// populate QueryParameters (sid/login_hint) and any other extraQueryParameters set by the developer
686686
if (ServerRequestParameters.isSSOParam(request) || account) {
687687
serverAuthenticationRequest.populateQueryParams(account, request, null, true);
688+
this.logger.verbose("Query parameters populated from existing SSO or account");
688689
}
689690
// if user didn't pass login_hint/sid and adal's idtoken is present, extract the login_hint from the adalIdToken
690691
else if (!account && !StringUtils.isEmpty(adalIdToken)) {
691692
// if adalIdToken exists, extract the SSO info from the same
692693
const adalIdTokenObject = TokenUtils.extractIdToken(adalIdToken);
693-
this.logger.verbose("ADAL's idToken exists. Extracting login information from ADAL's idToken ");
694+
this.logger.verbose("ADAL's idToken exists. Extracting login information from ADAL's idToken to populate query parameters");
694695
serverAuthenticationRequest.populateQueryParams(account, null, adalIdTokenObject, true);
695696
}
696-
697-
this.logger.verbose("Query parameters populated");
697+
else {
698+
this.logger.verbose("No additional query parameters added");
699+
}
698700

699701
const userContainedClaims = request.claimsRequest || serverAuthenticationRequest.claimsValue;
700702

@@ -737,7 +739,7 @@ export class UserAgentApplication {
737739
if (!serverAuthenticationRequest.authorityInstance) {
738740
serverAuthenticationRequest.authorityInstance = request.authority ? AuthorityFactory.CreateInstance(request.authority, this.config.auth.validateAuthority) : this.authorityInstance;
739741
}
740-
this.logger.verbose(`Authority instance: ${serverAuthenticationRequest.authority}`);
742+
this.logger.verbosePii(`Authority instance: ${serverAuthenticationRequest.authority}`);
741743

742744
// cache miss
743745

0 commit comments

Comments
 (0)